How To Wire A Stepper Motor To The Arduino Conveniently

While working on my Braille display, one problem I encountered early on was motor connecting – simply put, how to connect the motors to the driver board so I could disconnect them easily.

Since many driver boards have screw terminals, you’d think that’s as easy as it gets. However, try disconnecting two motors so as to redirect wires or move a motor; that means unscrewing as many as ten terminals. Plus, if you haven’t written down the order the wires go in, then it’s a game of “which wire goes where to work again?” until your motors are up and running.

I soon got fed up with that, and looked around for a simple plug option. Turns out the did the job nicely – four wires, ideal for a bipolar stepper motor. Once the motor is wired to the plug, adding/removing is a simple matter of unplugging. The mating connector stays attached to the board, and the wires are always arranged the same. So, even if I move my motor to another driver board, I simply make sure the motor connector is wired the same, and the motor’s plugs continue to work (simply set up and test with one motor, and I’m done).

One tricky thing about Molex power connectors: male versus female. The terminology is awkward since one plug has a female plastic cover, but male pins inside; it’s mate has a male plastic cover, and female pins. However, online the plastic cover seems to determine the gender, so the female one (with the male pins) is the plug you connect to the motor driver board screw terminals, and the male one is attached to each motor. Why? The male Molex connector is available everywhere, with a half dozen on the ends of wires in every computer power supply. the female however is rarer, since it’s usually the socket built into a peripheral. So since you only need one per motor board controller, it makes sense for it to be wired there, and use the more plentiful male connectors for the various motors.

To get them, search for , or buy those little power extenders, with usually two or three males and one female each. Another option is connectors, which turn out to be quite cheap in quantity. Just cut off the ends, attach where needed to the motor driver, and you have a simple solution for motor handling.

And by the way, what about unipolar motors, which have five or more wires? Since four are used for the drivers, and the remainder are grounds, connect the four as you would normally to the Molex plug, and add a single connector for the ground. I like to use a . Easy, and low cost.

SOME ITEMS YOU MIGHT ENJOY
L293D Motor Drive Shield Expansion Board For Arduino Duemilanove Mega KW
$2.29
End Date: Thursday Jan-11-2018 22:41:11 PST
Buy It Now for only: $2.29
Buy It Now | Add to watch list
Expansion card L293D motor drive Shield for Arduino blue V7Y7
$6.34
End Date: Thursday Jan-11-2018 13:02:26 PST
Buy It Now for only: $6.34
Buy It Now | Add to watch list
For Arduino UNO R3 MEGA2560 Mini L293D Motor Drive Shield Module Expansion Board
$1.42
End Date: Thursday Jan-11-2018 10:38:56 PST
Buy It Now for only: $1.42
Buy It Now | Add to watch list


Leave a Reply

Your email address will not be published. Required fields are marked *