mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-14 03:50:02 +03:00
Removed unused EXTI_CALLBACK_HANDLER_COUNT
This commit is contained in:
parent
ac4732cd03
commit
4d03791cbc
29 changed files with 68 additions and 131 deletions
|
@ -27,25 +27,6 @@
|
|||
|
||||
#include "system.h"
|
||||
|
||||
#ifndef EXTI_CALLBACK_HANDLER_COUNT
|
||||
#define EXTI_CALLBACK_HANDLER_COUNT 1
|
||||
#endif
|
||||
|
||||
extiCallbackHandlerConfig_t extiHandlerConfigs[EXTI_CALLBACK_HANDLER_COUNT];
|
||||
|
||||
void registerExtiCallbackHandler(IRQn_Type irqn, extiCallbackHandlerFunc *fn)
|
||||
{
|
||||
for (int index = 0; index < EXTI_CALLBACK_HANDLER_COUNT; index++) {
|
||||
extiCallbackHandlerConfig_t *candidate = &extiHandlerConfigs[index];
|
||||
if (!candidate->fn) {
|
||||
candidate->fn = fn;
|
||||
candidate->irqn = irqn;
|
||||
return;
|
||||
}
|
||||
}
|
||||
failureMode(FAILURE_DEVELOPER); // EXTI_CALLBACK_HANDLER_COUNT is too low for the amount of handlers required.
|
||||
}
|
||||
|
||||
// cycles per microsecond
|
||||
static uint32_t usTicks = 0;
|
||||
// current uptime for 1kHz systick timer. will rollover after 49 days. hopefully we won't care.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue