mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-15 20:35:33 +03:00
Relocated led strip user code into separate file.
Added documentation. Added LED_STRIP feature, can only be enabled under certain circumstances depending on target due to pin/timer mappings - see documentation.
This commit is contained in:
parent
3c09b6a8c7
commit
1730e3dfd3
11 changed files with 418 additions and 243 deletions
|
@ -198,6 +198,28 @@ void pwmInit(drv_pwm_config_t *init)
|
|||
continue;
|
||||
#endif
|
||||
|
||||
#if defined(STM32F10X_MD)
|
||||
#define LED_STRIP_PWM PWM4
|
||||
#endif
|
||||
|
||||
#if defined(STM32F303xC) && !(defined(CHEBUZZF3) || defined(NAZE32PRO))
|
||||
#define LED_STRIP_PWM PWM2
|
||||
#endif
|
||||
|
||||
#if defined(CHEBUZZF3)
|
||||
#define LED_STRIP_PWM PWM2
|
||||
#endif
|
||||
|
||||
#if defined(NAZE32PRO)
|
||||
#define LED_STRIP_PWM PWM13
|
||||
#endif
|
||||
|
||||
#ifdef LED_STRIP_PWM
|
||||
// skip LED Strip output
|
||||
if (init->useLEDStrip && timerIndex == LED_STRIP_PWM)
|
||||
continue;
|
||||
#endif
|
||||
|
||||
#ifdef STM32F10X_MD
|
||||
// skip ADC for RSSI
|
||||
if (init->useRSSIADC && timerIndex == PWM2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue