© Warren Gay 2018
Warren GayBeginning STM32https://doi.org/10.1007/978-1-4842-3624-6_16

16. PWM with Timer 2

Warren Gay1 
(1)
St. Catharines, Ontario, Canada
 

The STM32 family has a complex array of options available for operating timers. The STM32F103 has general-purpose timers TIM2, 3, 4, and 5 and then advanced timers TIM1 and TIM8. The general-purpose timers have plenty of features so you won’t need to reach for the advanced ones.

This chapter will demonstrate one of the frequently sought-after applications of a timerthat of driving a PWM (Pulse Width Modulated) servo motor. Figure 16-1 illustrates one example of a typical servo motor, which was pulled out of service.
Figure 16-1

A typical RC (Radio Controlled) servo motor (PKZ1081 SV80)

PWM Signals ...

Get Beginning STM32: Developing with FreeRTOS, libopencm3 and GCC 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.