PWM

Pulse Width Modulation, or PWM for brevity, is a commonly used technique to control different types of actuators, encode messages into signal with different pulse duration, and in general to generate pulses with fixed frequency and variable duty cycles on digital output lines for different purposes.

The timer interface may allow associating pins to output a PWM signal. On our reference microcontroller, four output compare channels can be associated to general-purpose timers, and the pins connected to the OC channels may be configured to output the encoded output automatically. On the STM32F407-Discovery board, the blue LED pin PD15, used in the previous example to demonstrate digital output functionality, is associated to the OC4 that ...

Get Embedded Systems Architecture now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.