Go Down

Topic: two steppers with arduino (Read 2349 times) previous topic - next topic

muddyd

Hi guys,
I'm using labVIEW interface for arduino to drive two stepper motors. I'm using two easy drivers on a single Arduino Uno. However, when I run both motors at the same time the speed of the motors drop. Each motor run smooth and fast individually. (with the same speed settings). So I'm curious whether a single arduino uno can run multiple steppers or whether it's best suited to drive one motor at a time.

Thank you !!

joemcder

From where do you derive the motor power?  Do not take it directly from the Arduino.

MarkT

[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

muddyd

Hi, I have two separate power supplies(12V each) for the easy drivers. I have the digital pins of arduino connected to the step and dir pins of easy drivers. As for the code, I'm using LabVIEW-Arduino interface so, all I have is the labVIEW firmware uploaded on the Arduino.

joemcder

The computational load on the Arduino is rather small due to the intelligence of the easy driver board.  2 motors is certainly no problem.

raacampbell

It sounds like you're not doing things in an optimal way, but it's hard to tell because you don't provide enough details on what you're doing. Saying "it's Labview" doesn't help much. For instance, is each step of the motor initiated by a new command from Labview? If you're sending the step commands sequentially to each motor then you may well end up with a lower speed. I think that's what you're doing.

The whole point of the Arduino is that it's a programmable real-time board. But it sounds like you're using it more like a cheap alternative to an NI USB-6009 (since we're talking NI products here). I think the problem is that you're not using the hardware to its full potential. Ditch the Labview interface and write your program in C as an Arduino sketch. You then control the Arduino via serial port commands (which can be send via the USB serial connection). The goal is not to have the PC tell the Arduino when to take each every step, but to tell it, say, "turn motor A clockwise at 300 RPM and motor B anticlockwise at 400 RPM" (or whatever). The PC sends one brief command and then the Arduino gets on with it until told otherwise. That's how a microcontroller is designed to be used.

Go Up