1*ec5a7997SFrançois Revol #ifndef KEYBOARD_H 2*ec5a7997SFrançois Revol #define KEYBOARD_H 3*ec5a7997SFrançois Revol 4*ec5a7997SFrançois Revol 5*ec5a7997SFrançois Revol #include <SupportDefs.h> 6*ec5a7997SFrançois Revol 7*ec5a7997SFrançois Revol 8*ec5a7997SFrançois Revol union key { 9*ec5a7997SFrançois Revol uint32 d0; 10*ec5a7997SFrançois Revol struct { 11*ec5a7997SFrançois Revol uint8 modifiers; // not always present! 12*ec5a7997SFrançois Revol uint8 bios; // scan code 13*ec5a7997SFrançois Revol uint8 dummy; 14*ec5a7997SFrançois Revol uint8 ascii; 15*ec5a7997SFrançois Revol } code; 16*ec5a7997SFrançois Revol }; 17*ec5a7997SFrançois Revol 18*ec5a7997SFrançois Revol #define BIOS_KEY_UP 0x48 19*ec5a7997SFrançois Revol #define BIOS_KEY_DOWN 0x50 20*ec5a7997SFrançois Revol #define BIOS_KEY_LEFT 0x4b 21*ec5a7997SFrançois Revol #define BIOS_KEY_RIGHT 0x4d 22*ec5a7997SFrançois Revol // XXX: FIXME 23*ec5a7997SFrançois Revol #define BIOS_KEY_HOME 0x47 24*ec5a7997SFrançois Revol #define BIOS_KEY_END 0x4f 25*ec5a7997SFrançois Revol #define BIOS_KEY_PAGE_UP 0x49 26*ec5a7997SFrançois Revol #define BIOS_KEY_PAGE_DOWN 0x51 27*ec5a7997SFrançois Revol 28*ec5a7997SFrançois Revol #ifdef __cplusplus 29*ec5a7997SFrançois Revol extern "C" { 30*ec5a7997SFrançois Revol #endif 31*ec5a7997SFrançois Revol 32*ec5a7997SFrançois Revol extern void clear_key_buffer(void); 33*ec5a7997SFrançois Revol extern union key wait_for_key(void); 34*ec5a7997SFrançois Revol extern uint32 check_for_boot_keys(void); 35*ec5a7997SFrançois Revol 36*ec5a7997SFrançois Revol #ifdef __cplusplus 37*ec5a7997SFrançois Revol } 38*ec5a7997SFrançois Revol #endif 39*ec5a7997SFrançois Revol 40*ec5a7997SFrançois Revol #endif /* KEYBOARD_H */ 41