Sign in to follow this  
Followers 0
Guest az_engineer

Can I write to Com1 as a file?

4 posts in this topic

I'd like to send commands and receive data from an RS232 serial port or a Windows Virtual Com Port.

Will that work? If so, is there a way to set the comm baud rate?

--az_engineer

Share this post


Link to post
Share on other sites



I don't believe that AutoIT has such a function ...yet.

Share this post


Link to post
Share on other sites

In the old days, we could talk to the com port like this:

echo atz > com1

In Autoit3 it would be:

Run( @Comspec '/c echo atz > com1' )

Or something like that ...

You had to have a program to get the result back though. I think I have an old one around here somewhere ...

Take care,

-Dw

---

"The crime bill passed by the Senate would reinstate the Federal death penalty for certain violent crimes: assassinating the President; hijacking an airliner; and murdering a government poultry inspector." - Knight Ridder News Service dispatch

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

you might be able to do it in perl (with a module)

but rebol can do it just fine. This is a small language but you could send Emails in a one line program so it is well built. Serial port comm is difficult because of the timing and buffering that is needed.( then again look at the samples)

this is a sample in rebol of talking to a GPS but it is full of comments

http://www.rebol.org/cgi-bin/cgiwrap/rebol...cript=gps-pos.r

Edited by normeus

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0