Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!wuarchive!emory!mephisto!gatech!galbp!gisatl!david From: david@gisatl.FIDONET.ORG (David Deitch) Newsgroups: comp.os.msdos.programmer Subject: Polling keyboard Message-ID: <432.26DFC08D@gisatl.FIDONET.ORG> Date: 1 Sep 90 02:59:23 GMT Organization: Galaxy Information System (GIS) 1:133/411 Atlanta, Ga Lines: 25 In a message of BBS Account (Aamir.Zakaria@samba.acs.unc.edu ) writes: > Can anyone tell me how, in either C or assembly language (8088), I can > poll > the keyboard for character input without actually waiting for input, > i.e. > just check if the user has hit a key. One of the INT 16 interrupts does this, but off the top of my head I can not remember which one. It will return the scan/key code of the key pressed or empty registers if none has been pressed. If it has been pressed, it is not taken out of the keyboard buffer. Use another one of those INT 16 functionoos for that. David Deitch (GIS) deitch@gisatl.fidonet.org 1:133/411@fidonet -- ----------------------------------------------------------------------------- David Deitch - via FidoNet node 1:133/411 UUCP: galbp!gisatl!david INTERNET: david@gisatl.FIDONET.ORG