decorative bevel

Servo signal explanation

Overview

Servo signals are pulse width modulated signals, repeated every 20 ms, that encode information by varying the width of the pulse of the signal. The signal is a square wave which is high for between 1 and 2 ms, though this varies between different servo manufacturers. The pulse length maps directly to the position of the servo, with the shortest length mapping to a full counter clockwise servo position, the longest pulse length mapping to a fully clockwise position, and intermediate pulse lengths mapping linearly to position.


Servo pulse lengths, and how they map to position (top) and continuous (bottom) servos


Continuous servos


Servos are often modified to move continuously so that they can be used as easily controllable low cost DC motors. The servo is then controlled the same way, but the pulse length now encodes velocity instead of position. The servo can be commanded to move clockwise and counterclockwise, with counterclockwise velocities increasing as the pulses get shorter, and clockwise velocities increasing as the pulse becomes longer - middle length pulses stop the servo.


Variations between servos


Servos come in a wide range of available torques and ranges of motion. They also vary in how the pulse length is encoded, such that servos from different manufacturers will react differently to the same pulse length. The Cerebellum servo routine allows the user to define the minimum and maximum pulse lengths, such that any servo's full range of motion can be used.