Commit Graph

7 Commits (d8c2c6f97fe419d682cdc11d859a4ce2952ca23d)

Author SHA1 Message Date
Alexandre Bourdiol a339084684 STM32: pwmout_write: configure channel only when not already enabled
Fix PWM glitch on write(), TARGET_STM/pwmout_api.c, #10734
2019-06-20 17:49:16 +02:00
Russ Butler be492fe07a Add HAL API for pwmout pinmap
Add the function pwm_pinmap to all targets.
2019-02-08 09:10:19 -06:00
Laurent Louf db3f05e5fe Add some rounding to determine the pulse value for PWM for the STM target. 2018-12-14 12:08:09 +01:00
jeromecoutant 433ba46132 TARGET_STM astyle 2018-06-27 14:21:07 +02:00
Laurent MEUNIER 3842f6ea0a STM32: fix formatting
Use the recommended style
if (condition) {
  do();
} else {
  do_else();
}
2017-02-27 17:07:05 +01:00
Laurent MEUNIER 8e5d2eb1dc STM32: pwm period and prescaler calculation
Correct the while loop limit and add a safe guard to avoid infinite loop.
2017-02-27 13:47:34 +01:00
Laurent MEUNIER 1cbb3e18ac STM32: make PWM driver into a common file
The pwmout driver is very similar for each STM32 family.

The only family specific part is defined in pwmout_device.h file.
It mainly contains few specific information:
- The mapping of PWM/TIMERS to APB1 or APB2 so that we can get the clock
- The clock calculation uses the right APB clock, which was sometimes
not the case before and could have lead to errors in case dividers were
enabled on APB clock settings. This case is now covered.
- Inactivation of inverted support on feaw families
2017-02-17 14:11:56 +01:00