reading from rs232 tty in ULTRIX

Rick Broberg rhb at bu-pub.bu.edu
Wed Jan 23 15:44:02 AEST 1991


I'm trying to read from a /dev/tty in ultrix which is the external
serial port on the machine.  I can open it, ioctl it for proper 
speed and data format configuration, even write to it just fine.
When I read from it, read *never* blocks, and multiple reads return
the same thing over and over, including some random junk.  Read doesn't
return -1 or 0, just random numbers.

Do I need to write a device driver for this?  If so, how?  Can I escape
having to?  If I must, why is it that the output to the port does work
but not the input.



More information about the Comp.unix.questions mailing list