Low-level PWM peripheral driver interface definitions. More...
Low-level PWM peripheral driver interface definitions.
Definition in file pwm.h.
#include <stdint.h>#include <limits.h>#include "periph_cpu.h"#include "periph_conf.h" Include dependency graph for pwm.h:
 Include dependency graph for pwm.h: This graph shows which files directly or indirectly include this file:
 This graph shows which files directly or indirectly include this file:Go to the source code of this file.
| Macros | |
| #define | PWM_DEV(x) | 
| Default PWM access macro. | |
| #define | PWM_UNDEF (UINT_FAST8_MAX) | 
| Default PWM undefined value. | |
| Typedefs | |
| typedef uint_fast8_t | pwm_t | 
| Default PWM type definition. | |
| Enumerations | |
| enum | pwm_mode_t { PWM_LEFT , PWM_RIGHT , PWM_CENTER } | 
| Default PWM mode definition.  More... | |
| Functions | |
| uint32_t | pwm_init (pwm_t dev, pwm_mode_t mode, uint32_t freq, uint16_t res) | 
| Initialize a PWM device. | |
| uint8_t | pwm_channels (pwm_t dev) | 
| Get the number of available channels. | |
| void | pwm_set (pwm_t dev, uint8_t channel, uint16_t value) | 
| Set the duty-cycle for a given channel of the given PWM device. | |
| void | pwm_poweron (pwm_t dev) | 
| Resume PWM generation on the given device. | |
| void | pwm_poweroff (pwm_t dev) | 
| Stop PWM generation on the given device. | |