delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/05/12/10:38:15

From: "Mr A Appleyard" <MCLSSAA2 AT fs2 DOT mt DOT umist DOT ac DOT uk>
Organization: Materials Science Centre
To: DJGPP AT delorie DOT com
Date: Tue, 12 May 1998 15:36:01 GMT
Subject: I wrote a TSR to read the raw keyboard events in DOS mode
Message-ID: <7F92846091@fs2.mt.umist.ac.uk>

  If anyone wants it, I wrote a program AAKEYS.COM which drops a TSR which
hooks interrupt 9 and adds more options to interrupt 0x16, so DOS programs can
read the raw keyboard events:-
    AX = 0x0600 : read from the key-event buffer one keyboard event and return
it in AL. Carry is clear. Prefix-code combinations are sent on as two events
as they are and are not decoded. Note two special return codes:-
      AL==0xff :  Here the key-event buffer got full. Note that the sequence
                  `prefix, 0xff' may occur.
      AL==0x00 and carry set : The key-event buffer was empty.
    AX = 0x0601 : Empty the key-event buffer.
    AX = 0x0602 : Try to remove this TSR.
    AX = 0x0603 : On return ES:BX points to AAKEYS's 256-byte circular buffer,
                  ES:AX points to that buffer's read & write pointers.
    AX = 0x0604 : Empty the ordinary keyboard buffer by resetting its pointers
    AX = 0x0605 : Stop sending the keyboard events on for usual processing.
    AX = 0x0606 : Resume sending the keyboard events on for usual processing.
    AX = any other 0x06** value: set AX to 0xBEEF (installation check).
    AX = any other value: what it did before.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019