Link to home
Start Free TrialLog in
Avatar of AustinKalb
AustinKalb

asked on

Unix keyboard I/O

How do I test for key pressed in UNIX? Better still, I am displaying data updates on a ASCII screen, and would like to lock the screen update function and invoke a command interpeter when the user presses a key. A getchar() function in a secondary thread does not seem to work well.
ASKER CERTIFIED SOLUTION
Avatar of kellyjj
kellyjj

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of AustinKalb
AustinKalb

ASKER

I am still struggling with this question. The old microsoft compiler had a "check keyboard buffer" function call. It returned a true when someone started typing on the keyboard, then I could go and get the data using a scanf or some other call. What I am really looking for is a way to to know someone want to type in a command without having to press return. For example, how would I read a function key without an eof after it?