mirror of
https://github.com/micropython/micropython.git
synced 2026-01-04 19:20:22 +01:00
stm32/led: Support PWM output without TIM3.
For example, the STM32WB55 doesn't have TIM3 but can still drive LEDs using PWM on other timers.
This commit is contained in:
@@ -141,9 +141,11 @@ STATIC void led_pwm_init(int led) {
|
||||
case 2:
|
||||
__TIM2_CLK_ENABLE();
|
||||
break;
|
||||
#if defined(TIM3)
|
||||
case 3:
|
||||
__TIM3_CLK_ENABLE();
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
assert(0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user