stepper motor wiring diagrans
Figure 1. Stepper motor wiring diagrams.
Use an ohm meter to determine type.

Arduino Unipolar Stepper Motor Control

by Lewis Loflin

For the hobbyist, one way to distinguish common wire from a coil-end wire is by measuring the resistance. Resistance between common wire and coil-end wire is always half of what it is between coil-end and coil-end wires. This is due to the fact that there is actually twice the length of coil between the ends and only half from center (common wire) to the end.

Here we will examine the basic operation of a unipolar stepper motor. I'll cover a bipolar stepper motor on a different page. A unipolar stepper motor has two windings per phase, one for each direction of magnetic field.

Since in this arrangement a magnetic pole can be reversed without switching the direction of current, the commutation circuit can be made very simple (eg. a single transistor) for each winding.

Typically, given a phase, one end of each winding is made common: giving three leads per phase and six leads for a typical two phase motor. Often, these two phase commons are internally joined, so the motor has only five leads. Others can have six leads.

A micro controller or stepper motor controller can be used to activate the drive transistors in the right order, and this ease of operation makes unipolar motors popular with hobbyists. They are probably the cheapest way to get precise angular movements.

Bipolar motor: Bipolar motors have a single winding per phase. The current in a winding needs to be reversed in order to reverse a magnetic pole, so the driving circuit must be more complicated, typically with an H-bridge arrangement. There are two leads per phase, none are common.

Stepper motors consist of a permanent magnet rotating shaft, called the rotor, and electromagnets on the stationary portion that surrounds the motor, called the stator. Controlling the sequence will cause the rotor to move. The electromagnets are energized by an external control circuit, such as a micro controller.

basic stepper motor construction
Figure 2. Basic stepper motor construction.

Two phases turned on for more torque
Figure 3. Two phases on for more torque.

When half stepping, the drive alternates between two phases on and a single phase on. This increases the angular resolution (less degrees per step), but the motor also has less torque at the half step position (where only a single phase is on). This may be mitigated by increasing the current in the active winding to compensate. The advantage of half stepping is that the drive electronics need not change to support it. In the examples below I only use two-phase single step for high torque.

For more technical detail see Stepper Motor Basis from Microchip. (PDF file)

arduino amd stepper motor
Schematic for this program.

Related Stepper motor Pages: