Its a trip for me to see stepper motors in consumer products. Dad used to sell stepper motors to industrial clients. I grew up with them, took demo's into career and technology fairs in grade school. Still remember the sound from the dining room as he'd program a demo - the whine noise of different speeds (most were larger than a lens). STMs work by way of counting steps, each a fraction of a degree around the circumference of the motor. Instructions from the software go something like:
rotate clockwise for x steps at y speed
rotate counterclockwise for x steps at y speed
rotate clockwise for x steps at y speed
rotate clockwise for x steps at y speed
Starting is precise, movement is precise, stopping is precise. And it turns out that for lenses, stopping is the most important (and difficult) part of autofocus. Older lenses push in a given direction but sort of guess at where to stop. Turn off power and it will probably land where its needed. Slower focus lenses actually had an advantage because stopping distance is easier to calculate.
In this age of precision, this is no longer enough. There are two ways to get hyper focus with a motor:
USM motor with focus detection unit, to measure the landing spot
Stepper motor with instructions to stop at the perfection spot
The best focusing newer lenses have one or the other
. This doesn't really help video for those cameras without video autofocus, but either is a major improvement for still shots.