Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!cs.utexas.edu!sdd.hp.com!uakari.primate.wisc.edu!zazen!schaefer.math.wisc.edu!mueller From: mueller@schaefer.math.wisc.edu (Carl Mueller) Newsgroups: comp.sys.amiga.programmer Subject: Checking for a Keystroke (in C) Message-ID: <1991Jun19.131033.14578@schaefer.math.wisc.edu> Date: 19 Jun 91 13:10:33 GMT Reply-To: mueller@math.wisc.edu Distribution: usa Organization: Univ. of Wisconsin Dept. of Mathematics Lines: 14 This question probably will require a somewhat lengthy answer. I hope that someone out there will take the time. I have the SAS/C compiler for the AMIGA and I want to write a routine that I can call that will check for a keypress. If a key is being pressed, I want the routine to report the key being pressed. If not I want it to return -1 or some such thing. Can anyone tell me how to do this (or direct me to some source code that does this)? I have a feeling that I'm going to have to use the keyboard device or the input device or the console device. If so, I'm really going to need some help getting started. Thanks much in advance. Carl Mueller (mueller@math.wisc.edu)