
This is taken from "The MSDOS Interrupt List", release 51, 7/28/96
Public Domain/Freeware/Shareware by Ralf Brown <ralf@pobox.com>
Probably available from
  http://www.pobox.com/~ralf
  ftp://ftp.cs.cmu.edu/afs/cs.cmu.edu/user/ralf/pub/
  ftp://ftp.simtel.net/pub/simtelnet/msdos/info/inter*
  ftp://garbo.uwasa.fi/pc/programming/inter*


--------H-09---------------------------------
INT 09 C - IRQ1 - KEYBOARD DATA READY
Desc:	this interrupt is generated when data is received from the keyboard.
	  This is normally a scan code (from either a keypress *or* a key
	  release), but may also be an ACK or NAK of a command on AT-class
	  keyboards.
Notes:	this IRQ may be masked by setting bit 1 on I/O port 21h
	if the BIOS supports an enhanced (101/102-key) keyboard, it calls
	  INT 15/AH=4Fh after reading the scan code (see #0005) from the
	  keyboard and before further processing; all further processing uses
	  the scan code returned from INT 15/AH=4Fh
	the default interrupt handler is at F000h:E987h in 100%-compatible
	  BIOSes
	the interrupt handler performs the following actions for certain
	  special keystrokes:
	    Ctrl-Break	 clear keyboard buffer, place word 0000h in buffer,
			 invoke INT 1B, and set flag at 0040h:0071h
	    SysReq	 invoke INT 15/AH=85h (SysReq is often labeled SysRq)
	    Ctrl-Numlock place system in a tight wait loop until next INT 09
	    Ctrl-Alt-Del jump to BIOS startup code (either F000h:FFF0h or the
			   destination of the jump at that address)
	    Shift-PrtSc	 invoke INT 05
	    Ctrl-Alt-Plus (HP Vectra) enable keyclick
	    Ctrl-Alt-Plus (many clones) set clock speed to high
	    Ctrl-Alt-Minus (HP Vectra) reduce keyclick volume
	    Ctrl-Alt-Minus (many clones) set clock speed to low
	    Ctrl-Alt-SysReq (HP Vectra) generate hard reset
	DR DOS hooks this interrupt to control the cursor shape (underscore/
	  half block) for overwrite/insert mode
	DR Multiuser DOS hooks this interrupt for cursor shape control and to
	  control whether Ctrl-Alt-Del reboots the current session or the
	  entire system
SeeAlso: INT 05,INT 0B"HP 95LX",INT 15/AH=4Fh,INT 15/AH=85h,INT 16,INT 1B
SeeAlso: INT 2F/AX=A901h,INT 4A"TI Professional",INT 51"DESQview"
SeeAlso: INT 59"DoubleDOS",INT 79"GO32"

(Table 0005)
Values for keyboard make/break (scan) code:
 01h	Esc		 31h	N
 02h	1 !		 32h	M
 03h	2 @		 33h	, <		 63h	F16
 04h	3 #		 34h	. >		 64h	F17
 05h	4 $		 35h	/ ?		 65h	F18
 06h	5 %		 36h	Right Shift	 66h	F19
 07h	6 ^		 37h	Grey*		 67h	F20
 08h	7 &		 38h	Alt		 68h	F21 (Fn) [*]
 09h	8 *		 39h	SpaceBar	 69h	F22
 0Ah	9 (		 3Ah	CapsLock	 6Ah	F23
 0Bh	0 )		 3Bh	F1		 6Bh	F24
 0Ch	- _		 3Ch	F2		 6Ch	--
 0Dh	= +		 3Dh	F3		 6Dh	EraseEOF
 0Eh	Backspace	 3Eh	F4
 0Fh	Tab		 3Fh	F5		 6Fh	Copy/Play
 10h	Q		 40h	F6
 11h	W		 41h	F7
 12h	E		 42h	F8		 72h	CrSel
 13h	R		 43h	F9		 73h	<delta> [*]
 14h	T		 44h	F10		 74h	ExSel
 15h	Y		 45h	NumLock		 75h	--
 16h	U		 46h	ScrollLock	 76h	Clear
 17h	I		 47h	Home
 18h	O		 48h	UpArrow
 19h	P		 49h	PgUp
 1Ah	[ {		 4Ah	Grey-
 1Bh	] }		 4Bh	LeftArrow
 1Ch	Enter		 4Ch	Keypad 5
 1Dh	Ctrl		 4Dh	RightArrow
 1Eh	A		 4Eh	Grey+
 1Fh	S		 4Fh	End
 20h	D		 50h	DownArrow
 21h	F		 51h	PgDn
 22h	G		 52h	Ins
 23h	H		 53h	Del
 24h	J		 54h	SysReq		---non-key codes---
 25h	K					 00h	kbd buffer full
 26h	L		 56h	left \| (102-key)
 27h	; :		 57h	F11		 AAh	self-test complete
 28h	' "		 58h	F12		 E0h	prefix code
 29h	` ~					 E1h	prefix code
 2Ah	Left Shift	 5Ah	PA1		 EEh	ECHO
 2Bh	\ |		 5Bh	F13 (LWin)	 F0h	prefix code (key break)
 2Ch	Z		 5Ch	F14 (RWin)	 FAh	ACK
 2Dh	X		 5Dh	F15 (Menu)	 FCh	diag failure (MF-kbd)
 2Eh	C					 FDh	diag failure (AT-kbd)
 2Fh	V					 FEh	RESEND
 30h	B					 FFh	kbd error/buffer full
Notes:	scan codes 56h-E1h are only available on the extended (101/102-key)
	  keyboard and Host Connected (122-key) keyboard; scan codes 5Bh-5Dh
	  are only available on the 122-key keyboard and the Microsoft Natural
	  Keyboard; scan codes 5Eh-76h are only available on the 122-key
	  keyboard
	in the default configuration, break codes are the make scan codes with
	  the high bit set; make codes 60h,61h,70h, etc. are not available
	  because the corresponding break codes conflict with prefix codes
	  (code 2Ah is available because the self-test result code AAh is only
	  sent on keyboard initialization).  An alternate keyboard
	  configuration can be enabled on AT and later systems with enhanced
	  keyboards, in which break codes are the same as make codes, but
	  prefixed with an F0h scan code
	prefix code E0h indicates that the following make/break code is for a
	  "gray" duplicate to a key which existed on the original PC keyboard;
	  prefix code E1h indicates that the following make code has no
	  corresponding break code (currently only the Pause key generates no
	  break code)
	the Microsoft Natural Keyboard sends make codes 5Bh, 5Ch, and 5Dh
	  (all with an E0h prefix) for the Left Windows, Right Windows, and
	  Menu keys on the bottom row
	the German "Cherry G81-3000 SAD/04" keyboard contains contacts for
	  four additional keys, which can be made available by a user
	  modification; the three new keys located directly below the cursor
	  pad's Delete, End, and PgDn keys send make codes 66h-68h (F19-F21);
	  the fourth new key, named <delta>, sends make code 73h
	the SysReq key is often labeled SysRq
	the "Accord" ergonomic keyboard with optional touchpad (no other
	  identification visible on keyboard or in owner's booklet) has an
	  additional key above the Grey- key marked with a left-pointing
	  triangle and labeled "Fn" in the owner's booklet which returns
	  scan codes E0h 68h on make and E0h E8h on break
SeeAlso: #0495 at INT 16/AX=6F07h
