A Brief Int 09h Overview

The BIOS Int 09h interrupt service routine processes the incoming scancode as follows:

  1. The routine reads the scancode from the keyboard I/O port (060h).
  2. Interrupts are enabled, the CARRY is set, and the Keyboard Translation Hook function (Int 15h, Fcn 4Fh) is called. An application can take over this hook and insert its own handler. If this call returns with carry clear, Int 09h stops processing and returns. If the carry is set, Int 09h proceeds with step 3.
  3. The routine checks for a Break (MENU Make ScanCode with CTRL Active). If the Break is detected, Int 09h clears the keyboard input buffer and calls Int 1Bh, described on page 3-130. (A "dummy" scancode of "00h/00h" is entered into the keyboard input buffer.)
  4. The Int 09h routine translates the scancode and enters the scancode and its ASCII equivalent into the keyboard input buffer. Some scancodes have no ASCII equivalent. In this case, Int 09h does one of the following:
Once a scancode/ASCII pair has been entered into the keyboard input buffer, an application can read the data by calling Int 16h. Depending on which Int 16h function is called, a further translation (or even a keycode discard) is possible.

Fn Key

Sticky Shift

Annunciators

Key Cap Legends

Scancode Conversion Tables

Shift Priority

Scancodes When Fn Function is Off

Scancodes When Fn Function is On

NumPad Scancodes (Menu Key Held Down)

Mute Key Sequences

Key Sequences For Char Codes 80h-8Fh