Stepper wiring

From RepRap
Revision as of 17:55, 28 April 2010 by Jgilmore (talk | contribs) (Final for now, I think. Instructions on how to determine the wiring of found steppers. Should be linked to in the FAQ probably.)
Jump to: navigation, search

There are two basic ways to drive a stepper motor, depending on if you can reverse the polarity on a coil or not. The reprap can and does, and this makes the "extra" wires on some stepper motors redundant. see [wikipedia] for more detailed information.

For our purposes, yes, unless it has five wires, it'll work fine.

This picture shows how ALL steppers are wired:

Unipolar-stepper-motor-windings.png

Four wire motors don't have the common wire.

Five wire motors have the two common wires on each coil connected internally, and exposed as only one wire. This configuration won't work for the standard reprap electronics, as the coils can't be independently reversed.

Six wire motors are wired as show.

Eight wire motors have two common wires for each of those coils, which don't connect. This divides this into four electrically separate coils.

So how do you determine which wire is which? Here's a process for you.

"pair" wires to determine coils

First, try turning the motor with your fingers, and notice how hard it is.

Second, twist all the wires together, and notice that it's much harder to turn. This is how you'll determine the coils.

third, pick a wire at random. This will be the first wire of pair one.

fourth, pick another wire at random and twist in together with the previous wire. Try twisting the motor. If it's just as easy to turn as it was in step one, it's the wrong wire, pick a different wire and try again. If it's the right wire, it'll be hard, but not as hard as it was in step two.

fifth, mark these wires as a coil and go back to step three.

You'll now have the wires paired up into coils. If you have a four wire motor, you're done. If you have a six wire motor, two of the wires are going to be "dead" and not attached to anything. So go back to step four, and find the wire with the GREATEST resistance to turning. If there are two that are equal, you picked the "dead" wire in step three, and the two others are your coil.

match coils

If you have a 8 wire stepper, you'll have 4 coils. You need to determine which pairs of coils are the "same". There are two "pairs" which are essentially the same. You want to hook these two pairs up in series so that you essentially have only two coils, each twice the length. You also need to hook them up so that the two coils "add" to eachother - polarity matters.

Good luck with that. Ask somebody wiser that I, probably on the forums. Then update this page with what they tell you.

Plug it into the stepper driver

The polarity of each coil doesn't matter, nor does which coil is which. So make sure each coil's wire is together on one side or the other of the plug, and plug it in.

It DOES actually matter which coil is which and what the polarity of the coils is, but if they're wrong the motor just turns the wrong way, which is easy to fix. Keep in mind the following:

1.Switching the polarity of either coil will reverse the stepper's direction.

2.Swapping the coils will reverse the stepper's direction.

3.The stepper direction can be reversed in the firmware.

4.Plugging the plug in backwards swaps the coils, and reversed both coil A and coil B. Thus the effect is to change the direction 3 times, which gives a net effect the same as changing the direction once.

Simplest solution to the stepper turning the wrong way is to turn the plug around, unless you've compiled your own firmware and already know how to reverse the direction in firmware.