10

Pulse Width Modulation (PWM)

This chapter concerns pulse width modulation (PWM), which is a digital signal easily generated by a MCU for a variety of purposes. These purposes commonly include controlling the following:

•   A standard servo motor’s position

•   The rotational speed of a continuous rotation servo

•   The luminescence of a light emitter

•   The rotation speed of a standard electric motor with external driver circuitry

•   A photovoltaic solar battery charger

•   The maximum power-point track

•   An output waveform such as sine, triangle, or square

•   An acoustic sound generator

This chapter’s projects will demonstrate how to control the luminescence (light intensity) of a normal LED, the color and luminescence of a tricolor ...

Get Programming with STM32: Getting Started with the Nucleo Board and C/C++ 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.