1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Serial Port communication

  1. Mar 27, 2009 #1
    Hi and thanks for your help

    I have a table in Excel spreadsheet which is containing data to motor through a stepper driver I can convert this spreadshhet by save as CSV file, the problem I have know is to write a programme in MS DOS throgh windows to send this CSV file to the serial port and wait for the feedback from the stepper driver to come back and then another 4 pice of stream data because the stepper driver does not have hand shacking, can you please help me how to write this programme in MS DOS, really Iam not familier with MS DOS programming and serial communication?



    Thanks for your help
     
  2. jcsd
  3. Mar 27, 2009 #2

    MATLABdude

    User Avatar
    Science Advisor

    Your question is a little ill-defined.

    Hardware-wise, is your stepper driver meant to be controlled with a serial port, or does it just take in waveforms to control the firing of the coils?

    Software-wise, do you actually have a Windows 3.1 / DOS setup? Or do you run something like XP, and mean that you need to write some kind of software (a console--i.e. non-GUI--program) to control the stepper driver?

    If you answer these, we may or may not be able to help you. Posting links to the hardware in question would also help.
     
  4. Mar 28, 2009 #3
    Thank you very much for your help

    Really the stepper driver will not be controlled by the serial port it just take in waveforms to control the firing of the coils? for the software I will run Windows XP and I need to writ a programme in MS-DOS after I run (cmd), the programme should send a stream of 7 bites each time to the stepper driver an wait for the driver feedback and send after another 7 bites to it till all the required bites will be send in this way to stepper drive actually it will be 3 stepper drivers (X, Y, Z), that's the jobe of the programme which I have to write it?



    Thanks for your help
     
  5. Mar 28, 2009 #4

    MATLABdude

    User Avatar
    Science Advisor

    Well, it really depends on what you're using as a stepper driver (and you *are* using a stepper driver, yes? A serial port will not supply enough current to drive a stepper motor). If you were using something like the following, you could control it with a serial port (and now you'll need to find out if you have unipolar or bipolar):
    http://store.qkits.com/moreinfo.cfm/KT-5197A
    http://www.active-robots.com/products/motorcon/ (scroll to the bottom of the page)

    More on stepper motors, and stepper motor control in general:
    http://www.cs.uiowa.edu/~jones/step/

    You are *NOT* writing a MS-DOS program, but rather a console program (one that doesn't have a user interface, like most Windows programs, and just pops up the text black and white DOS-like window). This wouldn't be too hard (with, say, Microsoft Visual C++ Express). You could quite easily read in a csv file and slowly spit out the bytes in the fashion you describe. But you'd need to do a fair bit of reading, and probably find a library or few.
     
  6. Mar 28, 2009 #5
    Hi

    Thanks for your reply

    Iam using a different power supply for the stepper motor and the stepper motor unipolar?
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Serial Port communication
  1. Digital Communications (Replies: 1)

  2. Serializing A Type (Replies: 2)

Loading...