[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Query
From: |
Przemek Klosowski |
Subject: |
Re: Query |
Date: |
Mon, 10 Nov 2003 17:25:27 -0500 (EST) |
On what platform? On Linux, you could probably get it like this:
octave:1 > system('stty crtscts 38400 </dev/ttyS0')
octave:2 > a=textread('/dev/ttyS0','%g')
On windows, I think the device property panel has settings for baud
rate, and I think it can also be set via the MODE command; in octave,
the textread('com1:','%g') should work.
I assume that the serial port doesn't have any particular protocol,
i.e. the data just keeps arriving at it, as is the case of simple
linear or electrical measurement devices.
If you have some sort of query-response protocol, I'd do it outside of
octave, via an external program, writing the results obtained from the
port to a pipe or file, which would then be read in octave, as above.
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
- Query, Prashant Lavti, 2003/11/09
- Re: Query,
Przemek Klosowski <=