Go Down

Topic: sending a motion command over serial (Read 566 times) previous topic - next topic

jpentlan

Hello,
I am relatively new to arduino, so please bear with me.  I have a stepper motor with built in motion control (IMS MDrive MDI23) I would like to control with my Arduino.  Normally, the command set for the stepper motor is given over an open serial port on the computer.  For example, to move the motor 5000 steps, the command would be "mr 5000" followed by a carriage return.  My question is, how do I get the arduino to send out that kind of command?  It would be a transmit only command i.e. there is no need for a receive command back.  I just need to transmit the commands.  Thanks
JOe

CrossRoads

Something simple, such as:

Serial.println ("mr 5000");

What is the electrical interface - do you need to be  a USB master, is it RS232 levels, is it simple TTL levels?
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

jpentlan

I used your suggestion of Serial.println("mr 5000").  When I open the serial monitor tool in the arduino software, I see mr 5000 print out, but nothing is happening with my motor.  I am trying to communicate over rs485.  I have the rs485 shield on the uno, but no luck.  I am guessing it is a communications issue, but I'm not exactly sure how to proceed.  Any suggestions would be appreciated. Thanks

PaulS

Quote
I am guessing it is a communications issue, but I'm not exactly sure how to proceed.

You could post links to the hardware in question, and a schematic, so that guessing wouldn't be required. It's up to you.

Go Up