A simple Step/Direction controller for Uni-polar Stepper?

Hello,

is there a circuit to control a 5 wire uni-polar stepper motor that would just take step and direction lines from the Arduino?

Why have a circuit when you could do it in software for free.
Any circuit would involve a bi directional binary counter and a couple of logic gates. No great shakes but not necessary.

Grumpy_Mike:
Why have a circuit when you could do it in software for free.
Any circuit would involve a bi directional binary counter and a couple of logic gates. No great shakes but not necessary.

Ah yesm but the problem is im planning on using these steppers with GRBL the gcode interpreter for arduino and it only gives its outputs as Step and Direction. I dont think i have enough skill to alter GRBL to produce unipolar pulses and think doing it in hardware would be easier?

Thanks for helping out :slight_smile:

I dont think i have enough skill to alter GRBL to produce unipolar pulses

OK then but it is simple enough.

and think doing it in hardware would be easier

Is your hardware sill up to doing it?
If so then:-
Take a 74LS193, it has two inputs count and direction. Take the bottom two output signals only, and use gates to generate the pattern you want. This pattern is shown here:-
http://www.thebox.myzen.co.uk/Workshop/Motors_3.html

Grumpy_Mike:

I dont think i have enough skill to alter GRBL to produce unipolar pulses

OK then but it is simple enough.

and think doing it in hardware would be easier

Is your hardware sill up to doing it?
If so then:-
Take a 74LS193, it has two inputs count and direction. Take the bottom two output signals only, and use gates to generate the pattern you want. This pattern is shown here:-
http://www.thebox.myzen.co.uk/Workshop/Motors_3.html

Could you point me in the right direction as to how i can edit the software? ill take a look at that first as you say its easy :slight_smile:

Look for the bit that outputs the step pulse and increment or decrement a counter depending on the step direction.
Make sure that the counter is restrained to the range 0 to 3 by ANDing the result with 3.
Then use that counter as an index to an array ( size of four ) which contains the bit pattern for your stepping motor. Then simply output the bits stored in that array.