|
RTEMS
5.1
|
Go to the documentation of this file. 19 #ifndef _I386_KEYBOARD_H 20 #define _I386_KEYBOARD_H 24 #define KEYBOARD_IRQ 1 25 #define DISABLE_KBD_DURING_INTERRUPTS 0 27 extern int pckbd_setkeycode(
unsigned int scancode,
unsigned int keycode);
28 extern int pckbd_getkeycode(
unsigned int scancode);
29 extern int pckbd_translate(
unsigned char scancode,
unsigned char *keycode,
31 extern char pckbd_unexpected_up(
unsigned char keycode);
32 extern void pckbd_leds(
unsigned char leds);
33 extern void pckbd_init_hw(
void);
34 extern unsigned char pckbd_sysrq_xlate[128];
36 #define kbd_setkeycode pckbd_setkeycode 37 #define kbd_getkeycode pckbd_getkeycode 38 #define kbd_translate pckbd_translate 39 #define kbd_unexpected_up pckbd_unexpected_up 40 #define kbd_leds pckbd_leds 41 #define kbd_init_hw pckbd_init_hw 42 #define kbd_sysrq_xlate pckbd_sysrq_xlate 44 #define SYSRQ_KEY 0x54 47 #define kbd_request_region() 48 #define kbd_request_irq(handler) 51 #define kbd_read_input() inb(KBD_DATA_REG) 52 #define kbd_read_status() inb(KBD_STATUS_REG) 53 #define kbd_write_output(val) outb(val, KBD_DATA_REG) 54 #define kbd_write_command(val) outb(val, KBD_CNTL_REG) 57 #define kbd_pause() do { } while(0) 65 #define aux_request_irq(hand, dev_id) 67 #define aux_free_irq(dev_id) 82 #define KBD_REPORT_UNKN 83 #define KBD_REPORT_TIMEOUTS 84 #undef KBD_IS_FOCUS_9000 85 #undef INITIALIZE_MOUSE 87 #define KBD_INIT_TIMEOUT 1000 88 #define KBC_TIMEOUT 250 89 #define KBD_TIMEOUT 1000 95 extern unsigned char pckbd_read_mask;
96 extern unsigned char aux_device_present;
102 #define KBD_STATUS_REG 0x64 103 #define KBD_CNTL_REG 0x64 104 #define KBD_DATA_REG 0x60 110 #define KBD_CCMD_READ_MODE 0x20 111 #define KBD_CCMD_WRITE_MODE 0x60 112 #define KBD_CCMD_GET_VERSION 0xA1 113 #define KBD_CCMD_MOUSE_DISABLE 0xA7 114 #define KBD_CCMD_MOUSE_ENABLE 0xA8 115 #define KBD_CCMD_TEST_MOUSE 0xA9 116 #define KBD_CCMD_SELF_TEST 0xAA 117 #define KBD_CCMD_KBD_TEST 0xAB 118 #define KBD_CCMD_KBD_DISABLE 0xAD 119 #define KBD_CCMD_KBD_ENABLE 0xAE 120 #define KBD_CCMD_WRITE_AUX_OBUF 0xD3 122 #define KBD_CCMD_WRITE_MOUSE 0xD4 128 #define KBD_CMD_SET_LEDS 0xED 129 #define KBD_CMD_SET_RATE 0xF3 130 #define KBD_CMD_ENABLE 0xF4 131 #define KBD_CMD_DISABLE 0xF5 132 #define KBD_CMD_RESET 0xFF 138 #define KBD_REPLY_POR 0xAA 139 #define KBD_REPLY_ACK 0xFA 140 #define KBD_REPLY_RESEND 0xFE 146 #define KBD_STAT_OBF 0x01 147 #define KBD_STAT_IBF 0x02 148 #define KBD_STAT_SELFTEST 0x04 149 #define KBD_STAT_CMD 0x08 150 #define KBD_STAT_UNLOCKED 0x10 151 #define KBD_STAT_MOUSE_OBF 0x20 152 #define KBD_STAT_GTO 0x40 153 #define KBD_STAT_PERR 0x80 155 #define AUX_STAT_OBF (KBD_STAT_OBF | KBD_STAT_MOUSE_OBF) 161 #define KBD_MODE_KBD_INT 0x01 162 #define KBD_MODE_MOUSE_INT 0x02 163 #define KBD_MODE_SYS 0x04 164 #define KBD_MODE_NO_KEYLOCK 0x08 165 #define KBD_MODE_DISABLE_KBD 0x10 166 #define KBD_MODE_DISABLE_MOUSE 0x20 167 #define KBD_MODE_KCC 0x40 168 #define KBD_MODE_RFU 0x80 174 #define AUX_SET_RES 0xE8 175 #define AUX_SET_SCALE11 0xE6 176 #define AUX_SET_SCALE21 0xE7 177 #define AUX_GET_SCALE 0xE9 178 #define AUX_SET_STREAM 0xEA 179 #define AUX_SET_SAMPLE 0xF3 180 #define AUX_ENABLE_DEV 0xF4 181 #define AUX_DISABLE_DEV 0xF5 182 #define AUX_RESET 0xFF 185 #define AUX_BUF_SIZE 2048