Class_Notes_Set_4

Class_Notes_Set_4 - Keyboard Programming INT 16H is an...

Info iconThis preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Keyboard Programming INT 16H is an interrupt specifically for use with keyboards. This interrupt allows for greater versatility in keyboard interfacing including the use of keys which does not generate an ASCII code, such as: F1, NumLock, etc. Keyboard Interrupt 16H Interrupt 16H Option 0H: Keyboard Read. Registers used: AH Key scan code. AL ASCII character. This option reads and removes one character from the keyboard buffer. If there isnt one it waits until a key is pressed. Keyboard Interrupt 16H Option 1H: Get keyboard status. Registers and flags used: ZF = 1 if no key is waiting. ZF = 0 if key is waiting: AH Key scan code. AL ASCII character. This option to see if there is a key waiting in the keyboard buffer. If a key press is waiting in the keyboard buffer, then ZF=0, and the codes are returned in AH and AL respectively. This function works like function 0 except the character is not removed from the keyboard buffer. Keyboard Interrupt 16H Option 2H: Get keyboard status bytes. Registers used: AL ASCII character. D0 Right Shift pressed; D1 Left shift pressed; D2 Ctrl pressed; D3 Alt pressed; D4 Scroll Lock state toggled; D5 NumLock state toggled; D6 CapsLock state toggled; D7 Insert toggled....
View Full Document

Page1 / 17

Class_Notes_Set_4 - Keyboard Programming INT 16H is an...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online