Jo�o Coimbra wrote:
> 
> Hi all how can I read a sonnar through a serial port (rs-232
> communication)? There is some example to help me?
> Thank you !!!
> 
> -- [rtl] ---
> To unsubscribe:
> echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
> echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
> --
> For more information on Real-Time Linux see:
> http://www.rtlinux.org/

It's probably NMEA. This is an international standard, also known
as  IEC 1162.

The messages are human readable text, you can use minicom to
see them. 

>From a sonar you probably get $SD (depth sounder) and $SS 
(scanning sounder) messages.

e.g. depth message:

$SDDPT,x,y,z*CC
       | |    |
       | |    +- Checksum
       | +- Transducer offset positive - distance to waterline
       |                      negative - distance to keel
       +- Water depth rel. to transducer in metres

Check the manufacturer's documentation, they usually support
a range of propietary messages.

The simplest way to read a serial port is probably this:

> stty -F /dev/ttyS0 ispeed 4800 ospeed 4800   # this is COM1, 4800 Bits/s
> cat /dev/ttyS0

Iwo
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
--
For more information on Real-Time Linux see:
http://www.rtlinux.org/

Reply via email to