1 /* 2 * Copyright 2004-2010, Haiku Inc. All Rights Reserved. 3 * Distributed under the terms of the MIT License. 4 */ 5 #ifndef _USB_HID_PAGE_KEYBOARD_H 6 #define _USB_HID_PAGE_KEYBOARD_H 7 8 9 /* Reference: 10 * HID Usage Page 0x07: KEYBOARD 11 * HID Usage Tables Ver. 1.12 12 * http://www.usb.org/developers/devclass_docs/Hut1_12.pdf 13 */ 14 15 // Usage IDs 16 enum { 17 B_HID_UID_KB_ERROR_ROLL_OVER = 0x01, 18 B_HID_UID_KB_POST_FAIL, 19 B_HID_UID_KB_ERROR_UNDEFINED, 20 21 B_HID_UID_KB_a_AND_A = 0x04, 22 B_HID_UID_KB_b_AND_B, 23 B_HID_UID_KB_c_AND_C, 24 B_HID_UID_KB_d_AND_D, 25 B_HID_UID_KB_e_AND_E, 26 B_HID_UID_KB_f_AND_F, 27 B_HID_UID_KB_g_AND_G, 28 B_HID_UID_KB_h_AND_H, 29 B_HID_UID_KB_i_AND_I, 30 B_HID_UID_KB_j_AND_J, 31 B_HID_UID_KB_k_AND_K, 32 B_HID_UID_KB_l_AND_L, 33 B_HID_UID_KB_m_AND_M, 34 B_HID_UID_KB_n_AND_N, 35 B_HID_UID_KB_o_AND_O, 36 B_HID_UID_KB_p_AND_P, 37 B_HID_UID_KB_q_AND_Q, 38 B_HID_UID_KB_r_AND_R, 39 B_HID_UID_KB_s_AND_S, 40 B_HID_UID_KB_t_AND_T, 41 B_HID_UID_KB_u_AND_U, 42 B_HID_UID_KB_v_AND_V, 43 B_HID_UID_KB_w_AND_W, 44 B_HID_UID_KB_x_AND_X, 45 B_HID_UID_KB_y_AND_Y, 46 B_HID_UID_KB_z_AND_Z, 47 48 B_HID_UID_KB_1_AND_EXCLAMATION_MARK = 0x1e, 49 B_HID_UID_KB_2_AND_AT, 50 B_HID_UID_KB_3_AND_HASH, 51 B_HID_UID_KB_4_AND_DOLLAR, 52 B_HID_UID_KB_5_AND_PERCENT, 53 B_HID_UID_KB_6_AND_CIRCUMFLEX, 54 B_HID_UID_KB_7_AND_AMPERSAND, 55 B_HID_UID_KB_8_AND_ASTERISK, 56 B_HID_UID_KB_9_AND_LPAREN, 57 B_HID_UID_KB_0_AND_RPAREN, 58 59 B_HID_UID_KB_ENTER = 0x28, 60 B_HID_UID_KB_ESCAPE, 61 B_HID_UID_KB_DELETE, 62 B_HID_UID_KB_TAB, 63 B_HID_UID_KB_SPACEBAR, 64 B_HID_UID_KB_DASH_AND_UNDERSCORE, 65 B_HID_UID_KB_EQUAL_SIGN_AND_PLUS, 66 B_HID_UID_KB_LBRACKET_AND_LBRACE, 67 B_HID_UID_KB_RBRACKET_AND_RBRACE, 68 B_HID_UID_KB_BACKSLASH_AND_PIPE, 69 B_HID_UID_KB_NON_US_HASH_AND_TILDE, // some notes 70 B_HID_UID_KB_SEMICOLON_AND_COLON, 71 B_HID_UID_KB_APOSTROPHE_AND_QUOTATION_MARK, 72 B_HID_UID_KB_GRAVE_ACCENT_AND_TILDE, 73 B_HID_UID_KB_COMMA_AND_LCHEVRON, 74 B_HID_UID_KB_PERIOD_AND_RCHEVRON, 75 B_HID_UID_KB_SLASH_AND_QUESTION_MARK, 76 B_HID_UID_KB_CAPS_LOCK, 77 78 B_HID_UID_KB_F1 = 0x3a, 79 B_HID_UID_KB_F2, 80 B_HID_UID_KB_F3, 81 B_HID_UID_KB_F4, 82 B_HID_UID_KB_F5, 83 B_HID_UID_KB_F6, 84 B_HID_UID_KB_F7, 85 B_HID_UID_KB_F8, 86 B_HID_UID_KB_F9, 87 B_HID_UID_KB_F10, 88 B_HID_UID_KB_F11, 89 B_HID_UID_KB_F12, 90 91 B_HID_UID_KB_PRINT_SCREEN = 0x46, 92 B_HID_UID_KB_SCROLL_LOCK, 93 B_HID_UID_KB_PAUSE, 94 B_HID_UID_KB_INSERT, 95 B_HID_UID_KB_HOME, 96 B_HID_UID_KB_PAGE_UP, 97 B_HID_UID_KB_DELETE_FORWARD, 98 B_HID_UID_KB_END, 99 B_HID_UID_KB_PAGE_DOWN, 100 B_HID_UID_KB_RIGHT_ARROW, 101 B_HID_UID_KB_LEFT_ARROW, 102 B_HID_UID_KB_DOWN_ARROW, 103 B_HID_UID_KB_UP_ARROW, 104 B_HID_UID_KB_NUM_LOCK_AND_CLEAR, 105 106 B_HID_UID_KP_DIVIDE = 0x54, 107 B_HID_UID_KP_MULTIPLY, 108 B_HID_UID_KP_SUBTRACT, 109 B_HID_UID_KP_ADD, 110 B_HID_UID_KP_ENTER, 111 B_HID_UID_KP_1_AND_END, 112 B_HID_UID_KP_2_AND_DOWN_ARROW, 113 B_HID_UID_KP_3_AND_PAGE_DOWN, 114 B_HID_UID_KP_4_AND_LEFT_ARROW, 115 B_HID_UID_KP_5, 116 B_HID_UID_KP_6_AND_RIGHT_ARROW, 117 B_HID_UID_KP_7_AND_HOME, 118 B_HID_UID_KP_8_AND_UP_ARROW, 119 B_HID_UID_KP_9_AND_PAGE_UP, 120 B_HID_UID_KP_0_AND_INSERT, 121 B_HID_UID_KP_PERIOD_AND_DELETE, 122 123 B_HID_UID_KB_NON_US_BACKSLASH_AND_PIPE = 0x64, 124 B_HID_UID_KB_APPLICATION, 125 B_HID_UID_KB_POWER, 126 127 B_HID_UID_KP_EQUAL_SIGN = 0x67, 128 B_HID_UID_KB_F13, 129 B_HID_UID_KB_F14, 130 B_HID_UID_KB_F15, 131 B_HID_UID_KB_F16, 132 B_HID_UID_KB_F17, 133 B_HID_UID_KB_F18, 134 B_HID_UID_KB_F19, 135 B_HID_UID_KB_F20, 136 B_HID_UID_KB_F21, 137 B_HID_UID_KB_F22, 138 B_HID_UID_KB_F23, 139 B_HID_UID_KB_F24, 140 141 B_HID_UID_KB_EXECUTE = 0x74, 142 B_HID_UID_KB_HELP, 143 B_HID_UID_KB_MENU, 144 B_HID_UID_KB_SELECT, 145 B_HID_UID_KB_STOP, 146 B_HID_UID_KB_AGAIN, 147 B_HID_UID_KB_UNDO, 148 B_HID_UID_KB_CUT, 149 B_HID_UID_KB_COPY, 150 B_HID_UID_KB_PASTE, 151 B_HID_UID_KB_FIND, 152 B_HID_UID_KB_MUTE, 153 B_HID_UID_KB_VOLUME_UP, 154 B_HID_UID_KB_VOLUME_DOWN, 155 B_HID_UID_KB_LOCKING_CAPS_LOCK, 156 B_HID_UID_KB_LOCKING_NUM_LOCK, 157 B_HID_UID_KB_LOCKING_SCROLL_LOCK, 158 159 B_HID_UID_KP_COMMA = 0x85, 160 B_HID_UID_KB_EQUAL_SIGN, 161 162 B_HID_UID_KB_INTERNATIONAL_1 = 0x87, 163 B_HID_UID_KB_INTERNATIONAL_2, 164 B_HID_UID_KB_INTERNATIONAL_3, 165 B_HID_UID_KB_INTERNATIONAL_4, 166 B_HID_UID_KB_INTERNATIONAL_5, 167 B_HID_UID_KB_INTERNATIONAL_6, 168 B_HID_UID_KB_INTERNATIONAL_7, 169 B_HID_UID_KB_INTERNATIONAL_8, 170 171 B_HID_UID_KB_LANG_1 = 0x90, 172 B_HID_UID_KB_LANG_2, 173 B_HID_UID_KB_LANG_3, 174 B_HID_UID_KB_LANG_4, 175 B_HID_UID_KB_LANG_5, 176 B_HID_UID_KB_LANG_6, 177 B_HID_UID_KB_LANG_7, 178 B_HID_UID_KB_LANG_8, 179 B_HID_UID_KB_LANG_9, 180 181 B_HID_UID_KB_ALTERNATE_ERASE = 0x99, 182 B_HID_UID_KB_SYSREQ_ATTENTION, 183 B_HID_UID_KB_CANCEL, 184 B_HID_UID_KB_CLEAR, 185 B_HID_UID_KB_PRIOR, 186 B_HID_UID_KB_RETURN, 187 B_HID_UID_KB_SEPARATOR, 188 B_HID_UID_KB_OUT, 189 B_HID_UID_KB_OPER, 190 B_HID_UID_KB_CLEAR_AGAIN, 191 B_HID_UID_KB_CRSEL_PROPS, 192 B_HID_UID_KB_EXSEL, 193 194 B_HID_UID_KB_00 = 0xb0, 195 B_HID_UID_KB_000, 196 B_HID_UID_KB_THOUSANDS_SEPARATOR, 197 B_HID_UID_KB_DECIMAL_SEPARATOR, 198 B_HID_UID_KB_CURRENCY_UNIT, 199 B_HID_UID_KB_CURRENCY_SUBUNIT, 200 201 B_HID_UID_KP_LPAREN = 0xb6, 202 B_HID_UID_KP_RPAREN, 203 B_HID_UID_KP_LBRACE, 204 B_HID_UID_KP_RBRACE, 205 B_HID_UID_KP_TAB, 206 B_HID_UID_KP_BACKSPACE, 207 B_HID_UID_KP_A, 208 B_HID_UID_KP_B, 209 B_HID_UID_KP_C, 210 B_HID_UID_KP_D, 211 B_HID_UID_KP_E, 212 B_HID_UID_KP_F, 213 B_HID_UID_KP_XOR, 214 B_HID_UID_KP_CIRCUMFLEX, 215 B_HID_UID_KP_PERCENT, 216 B_HID_UID_KP_LCHEVRON, 217 B_HID_UID_KP_RCHEVRON, 218 B_HID_UID_KP_AMPERSAND, 219 B_HID_UID_KP_AMPERSAND2, 220 B_HID_UID_KP_PIPE, 221 B_HID_UID_KP_PIPE2, 222 B_HID_UID_KP_COLON, 223 B_HID_UID_KP_HASH, 224 B_HID_UID_KP_SPACE, 225 B_HID_UID_KP_AT, 226 B_HID_UID_KP_EXCLAMATION_MARK, 227 B_HID_UID_KP_MEMORY_STORE, 228 B_HID_UID_KP_MEMORY_RECALL, 229 B_HID_UID_KP_MEMORY_CLEAR, 230 B_HID_UID_KP_MEMORY_ADD, 231 B_HID_UID_KP_MEMORY_SUBTRACT, 232 B_HID_UID_KP_MEMORY_MULTIPLY, 233 B_HID_UID_KP_MEMORY_DIVIDE, 234 B_HID_UID_KP_PLUS_MINUS, 235 B_HID_UID_KP_CLEAR, 236 B_HID_UID_KP_CLEAR_ENTRY, 237 B_HID_UID_KP_BINARY, 238 B_HID_UID_KP_OCTAL, 239 B_HID_UID_KP_DECIMAL, 240 B_HID_UID_KP_HEXADECIMAL, 241 242 B_HID_UID_KB_LEFT_CONTROL = 0xe0, 243 B_HID_UID_KB_LEFT_SHIFT, 244 B_HID_UID_KB_LEFT_ALT, 245 B_HID_UID_KB_LEFT_GUI, 246 B_HID_UID_KB_RIGHT_CONTROL, 247 B_HID_UID_KB_RIGHT_SHIFT, 248 B_HID_UID_KB_RIGHT_ALT, 249 B_HID_UID_KB_RIGHT_GUI 250 }; 251 252 253 #endif // _USB_HID_PAGE_KEYBOARD_H 254