# Controlling multiple stepper motors using a single driver

I want to control ~50 stepper motors using a single driver, and use only one Arduino pin to control each motor.

Currently I'm using a single A4988 driver and a couple of 12v 1amp stepper motors to prototype a part of a machine as a proof of concept, but I need to use many larger motors and better drivers in near future.

As I don't need motors to work simultaneously, I want to use a single driver to control them all.

I tried to validate my idea using 4 different relays and it seems that motors work perfectly as my needs (I tested and switched between them in a 24 hours long test). But as transistors are much cheaper and smaller in size, I want to use them if possible.

I have programming background and never designed a circuit before, but bellow is a schematics that I designed to control two stepper motors with a single driver, I don't know what kind of transistors or resistors should I use, or is this schematics possible at all? (As I mentioned, I already used a "4 relay module" instead of transistors and it worked well).

here is the schematics:

Any help to fix the schematics problems and choosing transistors and resistors would be appreciated.

Thanks.

p.s. As everyone in the comment section is suggesting to use multiple drivers I want to clear it again: Using multiple drivers is not an option, because I need to control larger motors and I need more expensive driver, which I can't afford many of them in a prototype. Any suggestion to use a single driver to control many motors, preferably using a single pin per motor is considerable. Thanks.

• Honestly, A4988s are not very expensive, and it will probably be easier in the end to just use independent drivers for each motor, and select them from the microcontroller side. Feb 14 '20 at 16:16
• Agreed. Anything else is a bodge. Feb 14 '20 at 16:17
• your schematic diagram shows 5 data pins being used ... two drivers would use 6 data pins ... you may be able to use separate enable signals and connect the two step signals to one data pin ... same for the direction ... that would reduce the pin count to 4 pins or even 3 pins Feb 14 '20 at 17:43
• @antwon Your reasoning for not using mechanical relays is that they are more expensive. But you're planning on moving to larger motors. Wouldn't the price of the relays (which are usually very cheap) become irrelevant next to the price of each motor as you move to more expensive motors? "I have programming background and never designed a circuit before" seems a good reason for sticking to simpler circuits IMO. Feb 14 '20 at 19:12
• There is a potential complication that you should consider if you need to maintain precise position in between motor moves. Example: You set the relays to motor 1, move motor 1, switch the relays to motor 2, then move motor 2. Now you want to move motor 1 again, so you switch the relays back to 1. But, the controller and motor's phases may not match. You may need to move a few steps to re-synchronize. Your precise position has been lost. You will need to decide if this is an issue. Feb 14 '20 at 22:19