Tuesday, January 20, 2009

Driving a unipolar stepper with the Arduino

I decided to get around to playing with the Arduino again. I had a few unipolar stepper motors laying around so I decided that it was about time that I figured out how to interface them with the Arduino. The first hurdle was figuring out how to wire the motors. All three of the steppers are five wire unipolar, but none of them have wires. They all have PCB's with connectors on them. I had a connector or two that I took out of an HP printer so I just had to figure out which wire did what.

Finding the center tap on the motors was easy enough as you do so by using an ohmmeter to check the resistances between pairs of wires. The common power wire will be the one with only half as much resistance between it and all the others. Finding the order of the remaining four wires in the end required good old fashioned trail and error.

When I finally figured it out I made sure to label the wires. The wiring order worked on all three steppers, two of which are Mitsumi's and the third is a Minebea.

It was easy enough to get the stepper to turn once the wiring order was determined. The Arduino stepper library provides a pretty simple method of doing so. The Arduino website gives adequate instruction on figuring out how to use it so I won't bother documenting it again. I just figured that it might be helpful to post a picture of the wiring order that I found to be shared among the steppers that I have so that I may spare someone else the effort of figuring it out in the future.

1 comment:

Lee said...

I like the all wires blue color code! The NMB stepper I have has the same color code but at least that one had a data sheet. I forget how I figures out the one on the scanner I am playing with, it is marked MOTOTECH, and I think there was a data sheet for that one also. I finally got the forward and reverse buttons to work driving the stepper, still learning to program;-)
http://triggerdog.blogspot.com/2009/01/driving-stepper-motors-with-arduino.html