13 September 2002

A Closer Look at Stepper Motors

by Paul Dito

While stepper motors offer the opportunity for more precise control than typical DC motors, the requisite control circuitry for steppers is inherently more complex. It’s easy to show graphs and charts depicting the theory behind stepper control, but it’s not so easy for an inexperienced experimenter to interpret such information. In my opinion, the solution is to get you hands on some motors and start playing with them.

Steppers are readily available on the surplus market. There are different kinds of steppers available, all with different characteristics. Coil resistance, torque ratings, step angle, number of phases, voltage ratings, etc. are all characteristics to be considered when designing a stepper motor system

For basic experimentation purposes most of these characteristics won’t be important. When shopping, pick up two or three identical motors. When experimenting with systems that move on more than one axis you will want the motor performance to be very similar to get the most precision out of your setup.

Steppers come in two basic flavors: unipolar and bipolar. This designation refers to the way the internal connections to the coils are arranged (see figure 1). The difference is subtle, and either type will do for most purposes, but for the most part unipolar motors are easier to work with. The different types can usually be identified by the number of leads coming from the motor. Unipolar motors will have 3 leads for every two coils, while bipolar motors have 2 leads per coil. The number of coils is referred to as number of ‘phases’ of a stepper motor. We will be experimenting with four phase motors, the most common type, so keep your eye out for 6 lead unipolar, or 8 lead bipolar steppers.

Figure 1: Comparison of internal connections of bipolar (left) and unipolar steppers

Once you have a motor in hand the first thing to do is sort out the phase connections. Second hand steppers rarely come with documentation so you will probably have to identify the leads on your own. This is most easily done with a multimeter. Using the ohmmeter functions, test pairs of leads until you have determined the related connections. For a bipolar stepper one lead from each pair will serve as a common connection. For unipolars, each pair of phases will have a common.

After the connections are identified, now it’s time to determine the phase order. To refresh your memory, a stepper motor contains a collection of coils surrounding the shaft, or rotor. The coils are energized in a particular order, and as each coil, or phase, is energized in turn a magnet on the shaft moves toward that coil, completing a step. (see http://eio.com/step-rot.html for an animation of this process).

There are different ways to identify the phase order, but I’ll share the method I consider to be the easiest. All you need is a power supply with the correct voltage (the rated voltage is usually stamped on the motor, but if not, something around 12 volts should be safe). The voltage is not critical for testing purposes, and can be up to 100% of the rated voltage. With the common phase lead connected to the negative terminal of the power supply, I randomly touch one lead to the positive terminal of the power supply. The shaft will jump a small amount and align itself with regard to the energized coil (a mark or piece of tape on the shaft will make the movement easier to see). Using that as a ‘home’ position, I touch each other lead in succession with the positive voltage and note how the shaft turns. It would take long to puzzle out the remaining phases.

Photo 1. Click image to enlarge

After you have the phase order, you can hook the motor up to a test circuit and start experimenting with step speeds and torque. There are different ways to implement stepping, but the three most common are ‘wave’ stepping, 2 phase stepping, and half-stepping. Wave stepping energizes one coil at a time (the method used to determine the order) and consumes the least power. 2 phase stepping energizes two adjacent coils in each detent position and offers a better torque-speed product as well as better detent torque (ie better ‘brakes’ or holding power). Half stepping combines wave and 2 phase stepping, thus effectively providing an 8 phase sequence, allowing for further precision.

Schematic 1 shows a circuit that generates a 2 phase stepper sequence using only simple logic gates (see table 1 for the circuits output). The circuit is taken from Gordon McComb’s excellent book "Robot Builder’s Bonanza". Construction is very straightforward, just pay attention to the cross connections between the gates, it’s easy to get confused. Build schematic 1 first, and check the sequence by observing the LEDs (photo 1). If you don’t have a signal generator, Schematic 3 shows a simple 555 timer application that will do the job. Once you’re satisfied the circuit is generating the proper sequence, then add the power drivers and motor (see Schematic 2 for the circuit, and photo 2 for the completed circuit).

Step

Phase1

Phase2

Phase3

Phase4

1

ON

OFF

OFF

ON

2

ON

ON

OFF

OFF

3

OFF

ON

ON

OFF

4

OFF

OFF

ON

ON

Table 1

Photo 2. Click image to enlarge

 

If the motor simply stutters, or vibrates try varying the step speed. Otherwise you may have gotten the wrong phase sequence, try other permutations until the motor turns smoothly. Once it’s turning you can experiment with various loads, speeds and supply voltages to see which combination gives you the most torque.

Next time we’ll see how to use your computer for intelligent control of two motors simultaneously…..