Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/5/84; site unicus.UUCP
Path: utzoo!mnetor!yetti!unicus!emc
From: emc@unicus.UUCP (Eric M. Carroll)
Newsgroups: comp.unix.questions
Subject: Re: Keyboard Input (Revised Question) ...
Message-ID: <854@unicus.UUCP>
Date: Sun, 26-Jul-87 19:24:10 EDT
Article-I.D.: unicus.854
Posted: Sun Jul 26 19:24:10 1987
Date-Received: Wed, 29-Jul-87 04:41:50 EDT
References: <1043@bucsb.bu.edu.UUCP> <805@nu3b2.UUCP> <142@bby-bc.UUCP> <23758@sun.uucp> <290@ncrcan.UUCP>
Reply-To: emc@unicus.UUCP (Eric M. Carroll)
Organization: Unicus Corporation, Toronto, Ont, Canada
Lines: 20
Summary: Not for the faint of heart

greg@ncrcan.UUCP writes:
> Under system V if you wish to set the number of characters needed to satisfy
> a read request you can disable cononical processing and set VMIN and VTIME to
> values which represent the minimum number of characters needed to satisfy a
> read request and the minimum amount of time respectively.
> 
> You do this through an ioctl, setting the lflags to disable cononical 
> processing.  VMIN and VTIME are set in c_cc at VMIN and VTIME.
> (termio.c_cc[VMIN] and termio.c_cc[VTIME]).

It should be noted here that VTIME takes affect *AFTER* the first character is
received. ie the timeout is only for BETWEEN characters; the 0th to 1st
character transition is not covered in this timeout. Thus trying to check if 
there is anything in the queue by using VTIME and attempting to read one
character will fail. 
-- 
	Eric Carroll 			Unicus Corporation, Toronto Ont.
	Eric.M.Carroll@Unicus.COM				  (Internet)
	{seismo!mnetor, utzoo!utgpu!utcsri}!unicus!Eric.M.Carroll (dumb UUCP)
	mnetor!unicus!Eric.M.Carroll@seismo.css.GOV		  (dumb ARPA)