Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 1 Jun 1999 17:51:01 +0200
From:      Andre Albsmeier <andre.albsmeier@mchp.siemens.de>
To:        freebsd-questions@freebsd.org
Subject:   Advice for writing software using serial ports needed
Message-ID:  <19990601175101.A14395@internal>

next in thread | raw e-mail | index | archive | help
Because I hate to do it on DOS/Win95/WinNT, I would like to solve
the following problem on FreeBSD:

I have to write a small programm that sends data to a serial port.
The device on the serial port sends the data back (just like a
loopback interface with TX/RX and RTS/CTS connected together).
I need some advice or a pointer how to do this properly. I think
I have to:

1. open /dev/cuaa0
2. set baudrate, bits, ... somehow (ioctl, termios, ???)
3. write/read to/from it within a select() loop
4. ???

Now I am looking for a small piece of source which contains the
appropriate calls already so I don't have to think a lot. (Actually,
I would like to figure it out by myself but the software has to be
ready tomorrow evening, else I would have to do it on a Micro$oft
OS :-). I already looked at the minicom sources but they are to
complicated to understand them quickly...

Thanks for any hints!

	-Andre


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990601175101.A14395>