Whats a
Servo?
Servo motors look like a
rectangular box with a motor shaft coming out of one end and a connector with
three wires out of the other end. The three wires are V+, Control, and Ground.
Servos typically run on 5.0v, but they often work with voltages between 4 and 6
volts. The control line is used to position the servo. In an R/C model, this
line it attached to the radio reciever, on robots it is usually attached to the
processor.
Unlike general purpose motors, R/C servos are constrained from
full rotation. Instead they have a limited rotation of about 180 degrees or
less. Typical standard servos are the Futaba S148, Hitec's HS-303 and Hobbico's
CS-61.
Anatomy of a
Servo
Servos
are constructed from four basic pieces: A motor, some gears, a feedback device,
and a control board. In R/C servos, the feedback device is typically a
potentiometer (variable resistor). The motor, through a series of gears, turns
the output shaft and the potentiometer simultaneously.
The potentiometer is
fed into the servo control circuit and when the control circuit detects that the
position is correct, it stops the motor.
In tha picture below, you can see, the control circuitry,
the motor, a set of gears, and the case. You can also see the 3 wires that
connect to the outside world, the power, ground, and the control wire.
Internals of a Servo and Block Diagram |
Controlling a
Servo
Servos are controlled by sending them a variable width pulse. The
control signal is a pulse of 5 volts with a Frame rate F and a pulse width P.
Typical frame rates are 20ms, typically values of P vary from 1.0ms to 2.0mS. On
most servos, 1.5ms places the servo at the middle also known as the neutral
position.
With the picture at the left, it
is NOT to assum that servos can be commanded at only 3 positions, ANY position
can be achived, providing the width of the control pulse is between the min and
max range.
When servos are commanded to move to a particular position,
they will actively hold that position. Thus, if a servo is commanded to the
neutral position and an external force is present to push against the servo, the
servo will actively resist being moved out of that position.
Servos will
not hold their position forever though, the position pulse must be repeated to
instruct the servo to stay in position.
The maximum amount of time that can
pass before the servo will stop holding its position is at about 20 - 30 mS. You
can repeat the pulse more often than this, but not less often. Personally, I've
been able to control servos with Frame rates as low as
5ms.