Skip to main content

Section 11.2 Day 11 In-Class: Motors, the H-Bridge, and PWM

Today we work out what sets a motor’s speed, and then build the hardware that controls it. We will follow the actuator signal chain that carries a number out of the STM32C031C6 and turns it into motion, derive the relationship between the voltage at a motor’s terminals and the speed of its shaft, see how an H-bridge reverses a motor and how the TB6612 driver exposes that through a few logic pins, and then wire a motor and drive it: first by hand, to set its direction, and then under a program that ramps its speed with PWM.