1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-17 21:35:44 +03:00

Timer code simplification in preparation of led strip being assignable.

Moved some repeated code into timer.c - preparation for allowing resource command for led strip
This commit is contained in:
blckmn 2016-10-23 14:16:55 +11:00
parent d5e20232be
commit fe3ac4754e
14 changed files with 103 additions and 136 deletions

View file

@ -175,4 +175,10 @@ const timerHardware_t *timerGetByTag(ioTag_t tag, timerFlag_e flag);
#if defined(USE_HAL_DRIVER)
TIM_HandleTypeDef* timerFindTimerHandle(TIM_TypeDef *tim);
#else
void timerOCInit(TIM_TypeDef *tim, uint8_t channel, TIM_OCInitTypeDef *init);
void timerOCPreloadConfig(TIM_TypeDef *tim, uint8_t channel, uint16_t preload);
#endif
volatile timCCR_t *timerCCR(TIM_TypeDef *tim, uint8_t channel);
uint16_t timerDmaSource(uint8_t channel);