termio(7) and read(2) problem!

Michael michael at stb.UUCP
Wed Feb 8 08:50:56 AEST 1989


In article <7411 at chinet.chi.il.us> les at chinet.chi.il.us (Leslie Mikesell) writes:
>In article <137 at zebra.UUCP> vern at zebra.UUCP (Vernon C. Hoxie) writes:
>>
>>	I have been trying to write a test program for a Trailblazer.
>>It is connected to /dev/tty000.  The program opens this file with:
>>
>>	fd = open("/dev/tty000", O_RDWR | O_NDELAY);
>
>You probably need to use fcntl() to turn off the O_NDELAY before
>trying to use the port (set CLOCAL first if you need it).  Write()s
>don't wait for the hardware to be ready if you leave O_NDELAY
>set and strange things happen.  I have seen code that indicated that
>a close(open(/dev/ttywhatever,2) was needed to force the mode to
>changed.  Does anyone know which versions of unix require this?
>
>Les Mikesell

Does anyone know how to turn ON NDELAY for an already open file?
			Michael
: --- 
: Michael Gersten			 uunet.uu.net!stb!michael
:					crash!gryphon!denwa!stb!michael
: Coff Coff <=== Stop smoking.



More information about the Unix-pc.general mailing list