back to index

Model servo controller


Why
What
      Voltage regulator
      Timing generator
            Troubleshooting
      Servo terminal block
      Power wiring
TODO
Images

Why

For many small-scale robotics applications, RC servos are highly useful. An expedient way to control their position is useful for development and testing of mechanical assemblies without having to troubleshoot the mechanics and the electronics at once.

A device was built with four independent signal generators providing the control pulses to the servos, and one common voltage regulator to allow testing the servos' response within a range of voltages.


What

The device consists of two sub-blocks: the voltage regulator and the timing generators.

Voltage regulator

The power supply circuit is based on the venerable LM317 circuit. The potentiometer was adjusted by fixed resistors to provide voltage range between roughly 3-9 volts, allowing tests of servo response/controllability within a range of voltages.

A piece of aluminium rail was chosen as a makeshift heatsink for the LM317.

Timing generator

As the timing pulse generator, the also-venerable 555 timer IC was chosen. The original Ron Woodwart's circuit was chosen as the basis; minor tweaks were applied to slightly increase the output timing range (increasing the capacitor size, decreasing the timer resistor).

The circuit was adjusted to operate on frequency of about 48 Hz, producing positive pulses of width ranging between about 0.6-2.5 milliseconds (covering the 1-2 milliseconds for the nominal full-left to full-right servo range, with 1.5 milliseconds as the center, allowing some overtravel and testing for response of the servos to signals slightly outside of specs).

Each of the four channels has an enable/disable switch, allowing disconnection of the control signal from the servo and putting it into uncontrolled mode where the shaft can be moved mechanically without the servo trying to maintain position. This also helps to steady the servo when in position, as some cheaper servos have certain positions in which they tend to slightly oscillate.

The timing capacitor is assembled from two parallel capacitors, due to their ready availability in the parts bin.

The 555 timer is connected directly to the input of the servo; this makes it liable to damage. The chips were therefore placed into sockets, for easy repairs. SMD parts were chosen for most of the rest of the electronics as they are easier to work and the resulting circuit looks cleaner.

The circuit output frequency slightly depends on the pot position (the total duty cycle is the fixed time of the L period plus the adjustable time of the H period). As servos do not care much about the base frequency, this should not be a problem.

Troubleshooting

An unexpected problem was discovered during assembly; an aggressive flux paste was used for tinning the somewhat ancient piece of circuitboard and its residues were hygroscopic. The leakage current was high enough in comparison with the current through the 3.3 Mohm resistor; the frequencies of servo drivers 3 and 4 were much higher (about 200 and about 60 Hz) than the drivers 1 and 2. The problem was identified by breathing at the circuit and observing the change in frequency.

The timers were also operating at too low basic frequency, about 14 Hz (due to increase of the timing capacitor), causing the servo movement to be somewhat jerky and non-smooth. Thorough washing of the board and lowering the value of the 3M3 resistor to 1 megaohm eliminated both problems.

Servo terminal block

The terminal block for the servos was made from gold-coated two-line pin connectors. Each channel has two male and two female sets of pins, allowing simultaneous connection of one or more servos, voltmeter, oscilloscope, or other devices.

The control pins are marked with color corresponding to the color of the control knob.

Power wiring

The timers are sensitive to smooth power. The motors tend to draw a high amount of current when they move. Voltage sags during such events tended to destabilize the circuit and led to unsteady and sometimes somewhat bizzarre behavior of the servos.

The power bus was therefore split to the high-power and control branches, isolated with chokes and buffered with high-capacity electrolytic capacitors. Smaller tantalum capacitors are also added in the close vicinity of the 555 chips, for additional stability.


TODO


Images


Inside view

Timer board detail

Timer board detail

Timer board detail

Pots detail

Stabilizer on heatsink

Stabilizer on heatsink

Stabilizer on heatsink

Servo connectors block

Servo connectors block

Outside, front

Outside, back

Servo connection panel

Connected servos

Connected servos

If you have any comments or questions about the topic, please let me know here:
Your name:
Your email:
Spambait
Leave this empty!
Only spambots enter stuff here.
Feedback: