My first stepper motor

Hi guys, I have a couple of (dumb) questions for you.

I bought an Arduino UNO few days ago and I'm not exactly an electronics guru, but I managed to make it communicate with Processing building a simple mouse controlled plotter-like-thing with two servos.

Now I feel ready to make the step into accuracy :wink: and other desired characteristics by using stepper motors instead. I read some material but I'm still a little confused and in particular:

  • what exactly should I look at to prefer an unipolar to a bipolar type of motor (or vv)?
  • supposing I made up my mind, what kind of driver you'd suggest?

I saw there are several alternatives, from a shield (eg. the adafruit motorshield) to a couple of Easydriver (at spankfun), to a handful of ICs (eg. SN754410 or U2004). Since the cost variance for these configurations is in the order of tenth, I wonder what is the substantial difference because, as far as I can see, they look like doing the same thing.

So in the end, what's your advice? What kind of motor and configuration? what do you use in your applications?

Please also consider that my objectives for now are (strictly in order of importance):

  • try not to screw up (eg. burning my board, because that seems a frightfully common mistake dealing with steppers)
  • try to learn something while obtaining good results
  • try not to buy useless stuff

Thanks a lot!

Good luck - I've blown two Unos and two SN754410s so far. I haven't found anyone on this forum who seems to know this area. Only tips I can give you - make sure your wiring is correct before you supply any power at all. The Uno is not really protected - with one of them I connected my motor supply (12v) incorrectly late at night, spark and dead.

And use a separate supply to power the motor - NOT the Uno - that seems to be a cause of weird problems.

And the chip seems to get very hot - which perhaps explains why four pins (gnd) double as heatsinks. I would use an additional heatsink on the chip anyway.

And use AccelStepper library, it seems better than the one from this site.

I did have my motor working nicely for a few minutes...lots of torque. But then I had a couple of problems which overlapped, loose wiring, battery going flat etc which threw me. So maybe its not so difficult.

I'm trying to source an easydriver board locally - it is much simpler and also microsteps. It would have been far cheaper if I had just bought one in the first place

First of all thanks a lot for your replay.

I feel sorry for your UNOs, but that's one of the reasons why I'm interested with the hardware side of the issue. I get the additional power need, but not the difference between motor types and different drivers. I mean, have unipolar or bipolar specific purposes and characteristics (leaving the number of poles aside...)?
And what would be the benefit of using a shield instead of an IC (maybe some kind of protection against unintentional damages)?

I thought too that EasyDriver would be a good option, but to drive 2 motors maybe the shield (Motor Shield - Arduino motor/stepper/servo control, unfortunately unassembled) cold be an alternative worth considering.

Lot of current flowing in the circuit usually explains the heat and burns risk, but wouldn't well-placed diodes and fuses help (surely some driver designer already thought about it...)?

Any insight would be very appreciated.

My best advice on using any of the common h-bridge drivers out there (L293/SN754410 and L298 in particular) is to pay very close attention to the datasheet, and understand what you are doing. Also, be aware of what the current and voltage needs of what you are driving (DC or stepper); if your motor is over the maximum amount allowed by the driver (and note that the L298, for a -single- DC motor, can by bridged to allow it to control the motor up to 4 amps), then you can't use the driver. Also, if your motor is anywhere within 50 percent of the capacity of the IC, you almost certainly will need a heatsink for the IC. Finally, make sure you install any needed flyback diodes per the reference design in the datasheet (some versions of the L293/SN754410 don't need them - they have ones internal to the IC, but some -don't-; also, the L298 certainly doesn't, and you should use high-speed/fast-recovery shottky-type diodes). Also keep in mind any bypass capacitors, and anything else in the reference design (they didn't just put them there for looks!)...

I see, thanks for your replay. Anyway in the end I decided to buy a "complete" driver (trusting more its designer than my luck with IC... at least for now :wink: ). I couldn't decide between sparkfun's Easydriver and Adafruit Motorshield, so I'm giving both a try. I still can't judge which one is better, because they have different characteristics and, for what I see, they both seem to work fine.

The point now is that I'd also like to use a couple of motors I found in a inkjet printer and, due to the lack of specifications I set their characteristics with a less than extensive trial and error process. The quite sure info is that they're both bipolar, one has 96 and the other 200 steps per rev.
As for their voltage, my hazardous experimentation simply consisted in increasing it till the motor started working and I found out that 5/6 V seem to be enough to have a satisfying torque and performance in general at least for my needs.
In this condition I measured a peak of nearly 0.6 A running a single motor (for reasons unknown to me the interleaved mode is the one asking for more amperage, but whatever...) so I guess using both the units allowed by AF Motorshield means getting to the max for the circuit.

My question now is, based on your experience, do you think this data actually makes sense and are you aware of any particular problems in running a stepper motor with a power supply assigned in the empirical way illustrated above (which I've reasons to believe resulted in less volts than the ones suggested for these motors)?