Email Address:

Lost your password?

This is the legacy website; please use the new website.

Serial Stepper Motor Controller

It's easy to build, easy to program and controls up to four motors. Or cascade four units together to control up to 16 motors.

By Greg Radion

Until now, it has been relatively difficult for the experimenter to properly control stepper motors using a computer. That’s because most stepper motor kits sold today interface the step and direction inputs to a parallel port and then require you to write the software to switch these inputs.

If you need to incorporate limit switches and acceleration and deceleration of the stepper motor, what started out as a simple job turns out to be complicated and time consuming. What’s more, parallel port designs can generally control only one or two motors and some designs don’t allow multiple boards to be cascaded together.

Click for larger image
Fig.1: up to four Serial Stepper Motor Controller (SSMC) boards can be cascaded together, so that you can separately control up to 16 stepper motors from the PC. Note that each stepper is driven via a separate driver board (see text).

The Serial Stepper Motor Controller (SSMC) described here overcomes these problems. It’s a relatively compact microcontroller-based design that attaches to a PC’s serial port and provides control for up to four stepper motors (via a suitable driver board). What’s more, it does away with the need for special software to control the acceleration and deceleration of the motors. Instead, you just issue the basic commands and the software inside the microcontroller does all the hard work for you.

It’s really very easy to program. There are just nine commands (see Table 2) and these are all entered via a standard serial terminal program (eg, HyperTerminal). We’ll have more on this later.

Want to control more than four steppers? No problem – up to four Serial Stepper Motor Controller boards can be cascaded (or "ganged") together and individually addressed. This allows you to control up to 16 stepper motors, all from the one serial port.

You can’t do that with most parallel port designs and, in any case, the parallel port is rapidly disappearing (many laptops no longer include a parallel port, for example). And with the availability of cheap USB-to-serial converters, this controller could easily be adapted for use on any USB port.

Fig.1 shows how the SSMC boards are connected. Note that the SSMC board does not directly drive the motors, since it has no on-board driver circuitry. Instead, each stepper motor is driven via a separate driver board.

There are several stepper motor driver kits available that can be used with the SSMC board. These include kits K179 (unipolar) and K142B (bipolar) from Oatley Electronics. The unipolar driver board was originally published as the Mini-Stepper Motor Driver in the May 2002 issue of SILICON CHIP. It can control both 5-wire and 6-wire unipolar stepper motors, while the bipolar board controls 4-wire and 6-wire motors.

Each of these kits has step and direction signal inputs which allow the user to control the movement of the motor. The Serial Stepper Motor Controller simply connects to these step and direction inputs on the driver cards.

Share this Article: 

Privacy Policy  |  Advertise  |  Contact Us

Copyright © 1996-2021 Silicon Chip Publications Pty Ltd All Rights Reserved