18#define KBD_STATUS_REG 0x64
19#define KBD_CNTL_REG 0x64
20#define KBD_DATA_REG 0x60
22#define KBD_STAT_OBF 0x01
23#define KBD_STAT_IBF 0x02
25#define CTRL_WRITE_MOUSE 0xD4
30#define KBD_DISABLE_MOUSE 0xA7
31#define KBD_ENABLE_MOUSE 0xA8
33#define kbd_write_command(cmd) WRITE_PORT_UCHAR((PUCHAR)KBD_CNTL_REG,cmd)
34#define kbd_write_data(cmd) WRITE_PORT_UCHAR((PUCHAR)KBD_DATA_REG,cmd)
35#define kbd_read_input() READ_PORT_UCHAR((PUCHAR)KBD_DATA_REG)
36#define kbd_read_status() READ_PORT_UCHAR((PUCHAR)KBD_STATUS_REG)
40 "\000\0331234567890-=\177\t"
41 "qwertyuiop[]\r\000as"
42 "dfghjkl;'`\000\\zxcv"
43 "bnm,./\000*\000 \000\201\202\203\204\205"
44 "\206\207\210\211\212\000\000789-456+1"
45 "230\177\000\000\213\214\000\000\000\000\000\000\000\000\000\000"
48 "\000\033!@#$%^&*()_+\177\t"
49 "QWERTYUIOP{}\r\000AS"
50 "DFGHJKL:\"`\000\\ZXCV"
51 "BNM<>?\000*\000 \000\201\202\203\204\205"
52 "\206\207\210\211\212\000\000789-456+1"
53 "230\177\000\000\213\214\000\000\000\000\000\000\000\000\000\000"
106 static byte_t last_key = 0;
111 while (KeepRetrying ||
Retry-- > 0)
120 if (((scancode & 0x7F) == 42) || ((scancode & 0x7F) == 54))
122 shift = !(scancode & 0x80);
131 else if (last_key != scancode)
_In_ PSCSI_REQUEST_BLOCK _Out_ NTSTATUS _Inout_ BOOLEAN * Retry
static VOID KbdSendCommandToMouse(UCHAR Command)
#define kbd_read_status()
static unsigned char keyb_layout[2][128]
CHAR KdbpTryGetCharKeyboard(PULONG ScanCode, ULONG Retry)
#define kbd_write_command(cmd)
VOID KbdDisableMouse(VOID)
VOID KbdEnableMouse(VOID)
#define kbd_write_data(cmd)
#define KeStallExecutionProcessor(MicroSeconds)