Browse Source

Merge pull request #3527 from z14git/pwm_patch

add PWM1_CONFIG
Bernard Xiong 5 years ago
parent
commit
c88870bfd7
1 changed files with 11 additions and 0 deletions
  1. 11 0
      bsp/stm32/libraries/HAL_Drivers/config/f1/pwm_config.h

+ 11 - 0
bsp/stm32/libraries/HAL_Drivers/config/f1/pwm_config.h

@@ -17,6 +17,17 @@
 extern "C" {
 #endif
 
+#ifdef BSP_USING_PWM1
+#ifndef PWM1_CONFIG
+#define PWM1_CONFIG                             \
+    {                                           \
+       .tim_handle.Instance     = TIM1,         \
+       .name                    = "pwm1",       \
+       .channel                 = 0             \
+    }
+#endif /* PWM1_CONFIG */
+#endif /* BSP_USING_PWM1 */
+
 #ifdef BSP_USING_PWM2
 #ifndef PWM2_CONFIG
 #define PWM2_CONFIG                             \