Stepper Motors Basics: Types, Uses, and Working Principles
Get valuable resources straight to your inbox - sent out once per month
We value your privacy
In this article, we will cover the basics of stepper motors. You will learn about the working principles, construction, control methods, uses, and types of stepper motors, as well as its advantages and disadvantages.
Stepper Motor Basics
A stepper motor is an electric motor whose main feature is that its shaft rotates by performing steps, that is, by moving by a fixed amount of degrees. This feature is obtained thanks to the internal structure of the motor, and allows to know the exact angular position of the shaft by simply counting how may steps have been performed, with no need for a sensor. This feature also makes it fit for a wide range of applications.
Stepper Motor Working Principles
As all with electric motors, stepper motors have a stationary part (the stator) and a moving part (the rotor). On the stator, there are teeth on which coils are wired, while the rotor is either a permanent magnet or a variable reluctance iron core. We will dive deeper into the different rotor structures later. Figure 1 shows a drawing representing the section of the motor is shown, where the rotor is a variable-reluctance iron core.
Figure 1: Cross-Section of a Stepper Motor
The basic working principle of the stepper motor is the following: By energizing one or more of the stator phases, a magnetic field is generated by the current flowing in the coil and the rotor aligns with this field. By supplying different phases in sequence, the rotor can be rotated by a specific amount to reach the desired final position. Figure 2 shows a representation of the working principle. At the beginning, coil A is energized and the rotor is aligned with the magnetic field it produces. When coil B is energized, the rotor rotates clockwise by 60° to align with the new magnetic field. The same happens when coil C is energized. In the pictures, the colors of the stator teeth indicate the direction of the magnetic field generated by the stator winding.
Figure 2: Stepper Motor Steps
Stepper Motor Types and Construction
The performance of a stepper motor — both in terms of resolution (or step size), speed, and torque — is influenced by construction details, which at the same time may also affect how the motor can be controlled. As a matter of fact, not all stepper motors have the same internal structure (or construction), as there are different rotor and stator configurations.
For a stepper motor, there are basically three types of rotors:
- Permanent magnet rotor: The rotor is a permanent magnet that aligns with the magnetic field generated by the stator circuit. This solution guarantees a good torque and also a detent torque. This means the motor will resist, even if not very strongly, to a change of position regardless of whether a coil is energized. The drawbacks of this solution is that it has a lower speed and a lower resolution compared to the other types. Figure 3 shows a representation of a section of a permanent magnet stepper motor.
Figure 3: Permanent Magnet Stepper Motor
- Variable reluctance rotor: The rotor is made of an iron core, and has a specific shape that allows it to align with the magnetic field (see Figure 1 and Figure 2). With this solution it is easier to reach a higher speed and resolution, but the torque it develops is often lower and it has no detent torque.
- Hybrid rotor: This kind of rotor has a specific construction, and is a hybrid between permanent magnet and variable reluctance versions. The rotor has two caps with alternating teeth, and is magnetized axially. This configuration allows the motor to have the advantages of both the permanent magnet and variable reluctance versions, specifically high resolution, speed, and torque. This higher performance requires a more complex construction, and therefore a higher cost. Figure 3 shows a simplified example of the structure of this motor. When coil A is energized, a tooth of the N-magnetized cap aligns with the S-magnetized tooth of the stator. At the same time, due to the rotor structure, the S-magnetized tooth aligns with the N-magnetized tooth of the stator. Real motors have a more complex structure, with a higher number of teeth than the one shown in the picture, though the working principle of the stepper motor is the same. The high number of teeth allows the motor to achieve a small step size, down to 0.9°.
Figure 4: Hybrid Stepper Motor
The stator is the part of the motor responsible for creating the magnetic field with which the rotor is going to align. The main characteristics of the stator circuit include its number of phases and pole pairs, as well as the wire configuration. The number of phases is the number of independent coils, while the number of pole pairs indicates how main pairs of teeth are occupied by each phase. Two-phase stepper motors are the most commonly used, while three-phase and five-phase motors are less common (see Figure 5 and Figure 6).
Figure 5: Two-Phase Stator Winding (Left), Three-Phase Stator Winding (Right)
Figure 6: Two-Phase, Single-Pole Pair Stator (Left) and Two-Phase, Dipole Pair Stator (Right). The Letters Show the Magnetic Field Generated when Positive Voltage is Applied between A+ and A-.
Stepper Motor Control
We have seen previously that the motor coils need to be energized, in a specific sequence, to generate the magnetic field with which the rotor is going to align. Several devices are used to supply the necessary voltage to the coils, and thus allow the motor to function properly. Starting from the devices that are closer to the motor we have:
- A transistor bridge is the device physically controlling the electrical connection of the motor coils. Transistors can be seen as electrically controlled interrupters, which, when closed allow the connection of a coil to the electrical supply and thus the flow of current in the coil. One transistor bridge is needed for each motor phase.
- A pre-driver is a device that controls the activation of the transistors, providing the required voltage and current, it is in turn controlled by an MCU.
- An MCU is a microcontroller unit, which is usually programmed by the motor user and generates specific signals for the pre-driver to obtain the desired motor behavior.
Figure 7 shows a simple representation of a stepper motor control scheme. The pre-driver and the transistor bridge may be contained in a single device, called a driver.
Figure 7: Motor Control Basic Scheme
Stepper Motor Driver Types
There are different stepper motor drivers available on the market, which showcase different features for specific applications. The most important charactreristics include the input interface. The most common options are:
- Step/Direction – By sending a pulse on the Step pin, the driver changes its output such that the motor will perform a step, the direction of which is determined by the level on the Direction pin.
- Phase/Enable – For each stator winding phase, Phase determines the current direction and triggers Enable if the phase is energized.
- PWM – Directly controls the gate signals of the low-side and high-side FETs.
Another important feature of a stepper motor driver is if it is only able to control the voltage across the winding, or also the current flowing through it:
- With voltage control, the driver only regulates the voltage across the winding. The torque developed and the speed with which the steps are executed only depend on motor and load characteristics.
- Current control drivers are more advanced, as they regulate the current flowing through the active coil in order to have better control over the torque produced, and thus the dynamic behavior of the whole system.
Another feature of the motor that also affects control is the arrangement of the stator coils that determine how the current direction is changed. To achieve the motion of the rotor, it is necessary not only to energize the coils, but also to control the direction of the current, which determines the direction of the magnetic field generated by the coil itself (see Figure 8).
In stepper motors, the issue of controlling the current direction is solved with two different approaches.
Figure 8: Direction of the Magnetic Field based on the Direction of the Coil Current
In unipolar stepper motors, one of the leads is connected to the central point of the coil (see Figure 9). This allows to control the direction of the current using relatively simple circuit and components. The central lead (AM) is connected to the input voltage VIN (see Figure 8). If MOSFET 1 is active, the current flows from AM to A+. If MOSFET 2 is active, current flows from AM to A-, generating a magnetic field in the opposite direction. As pointed out above, this approach allows a simpler driving circuit (only two semiconductors needed), but the drawback is that only half of the copper used in the motor is used at a time, this means that for the same current flowing in the coil, the magnetic field has half the intensity compared if all the copper were used. In addition, these motors are more difficult to construct since more leads have to be available as motor inputs.
Figure 9: Unipolar Stepper Motor Driving Circuit
In bipolar stepper motors, each coil has only two leads available, and to control the direction it is necessary to use an H-bridge (see Figure 10). As shown in Figure 8, if MOSFETs 1 and 4 are active, the current flows from A+ to A-, while if MOSFETs 2 and 3 are active, current flows from A- to A+, generating a magnetic field in the opposite direction. This solution requires a more complex driving circuit, but allows the motor to achieve the maximum torque for the amount of copper that is used.
Figure 10: Bipolar Stepper Motor Driving Circuit
With technology progress, the advantages of unipolar are becoming less relevant, and bipolar steppers are currently the most popular.
Stepper Motor Driving Techniques
There are four different driving techniques for a stepper motor:
- In wave mode, only one phase at a time is energized (see Figure 11). For simplicity, we will say that the current is flowing in a positive direction if it is going from the + lead to the - lead of a phase (e.g. from A+ to A-); otherwise, the direction is negative. Starting from the left, the current is flowing only in phase A in the positive direction and the rotor, represented by a magnet, is aligned with the magnetic field generated by it. In the next step, it flows only in phase B in the positive direction, and the rotor spins 90° clockwise to align with the magnetic field generated by phase B. Later, phase A is energized again, but the current flows in the negative direction, and the rotor spins again by 90°. In the last step, the current flows negatively in phase B and the rotor spins again by 90°.
Figure 11: Wave Mode Steps
- In full-step mode, two phases are always energized at the same time. Figure 12 shows the different steps of this driving mode. The steps are similar to the wave mode ones, the most significant difference being that with this mode, the motor is able to produce a higher torque since more current is flowing in the motor and a stronger magnetic field is generated.
Figure 12: Full-Step Mode Steps
- Half-step mode is a combination of wave and full-step modes (see Figure 12). Using this combination allows for the step size to be reduced by half (in this case, 45° instead of 90°). The only drawback is that the torque produced by the motor is not constant, since it is higher when both phases are energized, and weaker when only one phase is energized.
Figure 13: Half-Step Mode Steps
- Microstepping can be seen as a further enhancement of half-step mode, because it allows to reduce even further the step size and to have a constant torque output. This is achieved by controlling the intensity of the current flowing in each phase. Using this mode requires a more complex motor driver compared to the previous solutions. Figure 14 shows how microstepping works. If IMAX is the maximum current that can flow in a phase, starting from the left, in the first figure IA = IMAX and IB = 0. In the next step, the currents are controlled to achieve IA = 0.92 x IMAX and IB = 0.38 x IMAX, which generates a magnetic field that is rotated by 22.5° clockwise compared to the previous one. This step is repeated with different current values to reach the 45°, 67.5°, and 90° positions. This provides the ability to reduce by half the size of the step, compared to the half-step mode; but it is possible to go even further. Using microstepping helps reaching very high position resolution, but this advantage comes at the cost of a more complex device to control the motor, and a smaller torque generated with each step. Indeed, the torque is proportional to the sine of the angle between the stator magnetic field and the rotor magnetic field; therefore, when the steps are smaller, the torque is smaller. This may lead to missing some steps, meaning the rotor position does not change even if the current in the stator winding has.
Figure 14: Microstepping
Stepper Motors Advantages and Disadvantages
Now that we understand the working principles of the stepper motors, it is useful to summarize their pros and cons compared to other motor types.
- Due to their internal structure, stepper motors do not require a sensor to detect the motor position. Since the motor moves by performing “steps,” by simply counting these steps, you can obtain the motor position at a given time.
- In addition, stepper motor control is pretty simple. The motor does need a driver, but does not need complex calculations or tuning to work properly. In general, the control effort is lower compared to other motors. With microstepping, you can reach high position accuracy, up to approximately 0.007°.
- Stepper motors offer good torque at low speeds, are great for holding position, and also tend to have a long lifespan.
- They can miss a step if the load torque is too high. This negatively impacts the control, since there is no way to know the real position of the motor. Using microstepping makes stepper motors even more likely to experience this issue.
- These motors always drain maximum current even when still, which makes efficiency worse and can cause overheating.
- Stepper motors have low torque and become pretty noisy at high speeds.
- Finally, stepper motors have low power density and a low torque-to-inertia ratio.
To summarize, stepper motors are good when you need an inexpensive, easy-to-control solution and when efficiency and high torque at high speeds are not necessary.
To learn more about how to pick the right type of motor for your project, and the differences between stepper, brushed, and brushless motors click here.
Stepper Motor Uses and Applications
Due to their properties, stepper motors are used in many applications where a simple position control and the ability to hold a position are needed, including:
Printers: Printheads, Paper Feed, Scan Bar
3D Printers: XY Table Drive, Media Drive
Robots: Arms, End Effectors
DSLR Cameras: Aperture/Focus Regulation
Video Cameras: Pan, Tilt, Zoom, Focus
Engraving Machines: XY Table Motion
ATM Machines: Bill Movement, Tray Elevators