1 /* Copyright (C) 2011-2014 by Jacob Alexander
3 * Permission is hereby granted, free of charge, to any person obtaining a copy
4 * of this software and associated documentation files (the "Software"), to deal
5 * in the Software without restriction, including without limitation the rights
6 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 * copies of the Software, and to permit persons to whom the Software is
8 * furnished to do so, subject to the following conditions:
10 * The above copyright notice and this permission notice shall be included in
11 * all copies or substantial portions of the Software.
13 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
25 // ----- Defines -----
27 // The USB codes are all taken from the USB HID Spec
28 // http://www.usb.org/developers/hidpage/Hut1_12v2.pdf (HID Usage Tables)
30 // List of Keycodes - USB HID 1.12v2 pg 53
31 #define KEY_NOEVENT 0x00 // Event, not a physical key
32 #define KEY_ERRORROLLOVER 0x01 // Event, not a physical key
33 #define KEY_POSTFAIL 0x02 // Event, not a physical key
34 #define KEY_ERRORUNDEFINED 0x03 // Event, not a physical key
71 #define KEY_ENTER 0x28
73 #define KEY_BACKSPACE 0x2A
75 #define KEY_SPACE 0x2C
76 #define KEY_MINUS 0x2D
77 #define KEY_EQUAL 0x2E
78 #define KEY_LEFT_BRACE 0x2F
79 #define KEY_RIGHT_BRACE 0x30
80 #define KEY_BACKSLASH 0x31
81 #define KEY_NUMBER 0x32
82 #define KEY_SEMICOLON 0x33
83 #define KEY_QUOTE 0x34
84 #define KEY_BACKTICK 0x35
85 #define KEY_COMMA 0x36
86 #define KEY_PERIOD 0x37
87 #define KEY_SLASH 0x38
88 #define KEY_CAPS_LOCK 0x39
101 #define KEY_PRINTSCREEN 0x46
102 #define KEY_SCROLL_LOCK 0x47
103 #define KEY_PAUSE 0x48
104 #define KEY_INSERT 0x49
105 #define KEY_HOME 0x4A
106 #define KEY_PAGE_UP 0x4B
107 #define KEY_DELETE 0x4C
109 #define KEY_PAGE_DOWN 0x4E
110 #define KEY_RIGHT 0x4F
111 #define KEY_LEFT 0x50
112 #define KEY_DOWN 0x51
114 #define KEY_NUM_LOCK 0x53
115 #define KEYPAD_SLASH 0x54
116 #define KEYPAD_ASTERIX 0x55
117 #define KEYPAD_MINUS 0x56
118 #define KEYPAD_PLUS 0x57
119 #define KEYPAD_ENTER 0x58
120 #define KEYPAD_1 0x59
121 #define KEYPAD_2 0x5A
122 #define KEYPAD_3 0x5B
123 #define KEYPAD_4 0x5C
124 #define KEYPAD_5 0x5D
125 #define KEYPAD_6 0x5E
126 #define KEYPAD_7 0x5F
127 #define KEYPAD_8 0x60
128 #define KEYPAD_9 0x61
129 #define KEYPAD_0 0x62
130 #define KEYPAD_PERIOD 0x63
131 #define KEY_ISO_SLASH 0x64
133 #define KEYBOARD_STATUS 0x66 // Used for indicating keyboard is on/status/errors, not a key
134 #define KEYPAD_EQUAL 0x67
147 #define KEY_EXEC 0x74
148 #define KEY_HELP 0x75
149 #define KEY_MENU 0x76
150 #define KEY_SELECT 0x77
151 #define KEY_STOP 0x78
152 #define KEY_AGAIN 0x79
153 #define KEY_UNDO 0x7A
155 #define KEY_COPY 0x7C
156 #define KEY_PASTE 0x7D
157 #define KEY_FIND 0x7E
158 #define KEY_MUTE 0x7F
159 #define KEY_VOL_UP 0x80
160 #define KEY_VOL_DOWN 0x81
161 #define KEY_CAPS_TLOCK 0x82 // Toggle "Locking" Scroll Lock (Old keyboards with Locking Caps Lock)
162 #define KEY_NUM_TLOCK 0x83
163 #define KEY_SCROLL_TLOCK 0x84
164 #define KEYPAD_COMMA 0x85 // Brazillian (See spec)
165 #define KEYPAD_EQUAL_AS 0x86 // AS/400 Keyboard (See spec)
166 #define KEY_INTER1 0x87 // KANJI1 - Brazillian and Japanese "Ru" and "-"
167 #define KEY_INTER2 0x88 // KANJI2 - Japanese Katakana/Hiragana
168 #define KEY_INTER3 0x89 // KANJI3 - Japanese Yen
169 #define KEY_INTER4 0x8A // KANJI4 - Japanese Henkan
170 #define KEY_INTER5 0x8B // KANJI5 - Japanese Muhenkan
171 #define KEY_INTER6 0x8C // KANJI6 - PC0x62 Comma (Ka-m-ma)
172 #define KEY_INTER7 0x8D // KANJI7 - Double-Byte/Single-Byte Toggle
173 #define KEY_INTER8 0x8E // KANJI8 - Undefined
174 #define KEY_INTER9 0x8F // KANJI9 - Undefined
175 #define KEY_LANG1 0x90 // Korean Hangul/English Toggle
176 #define KEY_LANG2 0x91 // Korean Hanja Conversion - Japanese Eisu
177 #define KEY_LANG3 0x92 // Japanese Katakana Key (USB)
178 #define KEY_LANG4 0x93 // Japanese Hiragana Key (USB)
179 #define KEY_LANG5 0x94 // Japanese Zenkaku/Hankaku Key (USB)
180 #define KEY_LANG6 0x95 // Reserved (Application Specific)
181 #define KEY_LANG7 0x96 // Reserved (Application Specific)
182 #define KEY_LANG8 0x97 // Reserved (Application Specific)
183 #define KEY_LANG9 0x98 // Reserved (Application Specific)
184 #define KEY_ALT_ERASE 0x99 // Special Erase (See Spec)
185 #define KEY_SYSREQ_ATT 0x9A // Modifier Type
186 #define KEY_CANCEL 0x9B
187 #define KEY_CLEAR 0x9C
188 #define KEY_PRIOR 0x9D
189 #define KEY_RETURN 0x9E
190 #define KEY_SEPARATOR 0x9F
192 #define KEY_OPER 0xA1
193 #define KEY_CLEAR_AGAIN 0xA2
194 #define KEY_CRSEL_PROPS 0xA3
195 #define KEY_EXSEL 0xA4
196 // 0xA5 - 0xAF Reserved
197 #define KEYPAD_00 0xB0
198 #define KEYPAD_000 0xB1
199 #define KEY_1000_SEP 0xB2
200 #define KEY_DECIMAL_SEP 0xB3
201 #define KEY_CURRENCY_MAIN 0xB4
202 #define KEY_CURRENCY_SUB 0xB5
203 #define KEYPAD_LPAREN 0xB6
204 #define KEYPAD_RPAREN 0xB7
205 #define KEYPAD_LBRACE 0xB8
206 #define KEYPAD_RBRACE 0xB9
207 #define KEYPAD_TAB 0xBA
208 #define KEYPAD_BACKSPACE 0xBB
209 #define KEYPAD_A 0xBC
210 #define KEYPAD_B 0xBD
211 #define KEYPAD_C 0xBE
212 #define KEYPAD_D 0xBF
213 #define KEYPAD_E 0xC0
214 #define KEYPAD_F 0xC1
215 #define KEYPAD_XOR 0xC2
216 #define KEYPAD_CHEVRON 0xC3
217 #define KEYPAD_PERCENT 0xC4
218 #define KEYPAD_LTHAN 0xC5
219 #define KEYPAD_GTHAN 0xC6
220 #define KEYPAD_BITAND 0xC7
221 #define KEYPAD_AND 0xC8
222 #define KEYPAD_BITOR 0xC9
223 #define KEYPAD_OR 0xCA
224 #define KEYPAD_COLON 0xCB
225 #define KEYPAD_POUND 0xCC
226 #define KEYPAD_SPACE 0xCD
227 #define KEYPAD_AT 0xCE
228 #define KEYPAD_EXCLAIM 0xCF
229 #define KEYPAD_MEM_STORE 0xD0
230 #define KEYPAD_MEM_RECALL 0xD1
231 #define KEYPAD_MEM_CLEAR 0xD2
232 #define KEYPAD_MEM_ADD 0xD3
233 #define KEYPAD_MEM_SUB 0xD4
234 #define KEYPAD_MEM_MULT 0xD5
235 #define KEYPAD_MEM_DIV 0xD6
236 #define KEYPAD_PLUS_MINUS 0xD7
237 #define KEYPAD_CLEAR 0xD8
238 #define KEYPAD_CLEAR_ENTRY 0xD9
239 #define KEYPAD_BINARY 0xDA
240 #define KEYPAD_OCTAL 0xDB
241 #define KEYPAD_DECIMAL 0xDC
242 #define KEYPAD_HEX 0xDD
243 // 0xDE - 0xDF Reserved
244 #define KEY_CTRL 0xE0 // Convenience
245 #define KEY_LCTRL 0xE0
246 #define KEY_SHIFT 0xE1 // Convenience
247 #define KEY_LSHIFT 0xE1
248 #define KEY_ALT 0xE2 // Convenience
249 #define KEY_LALT 0xE2
250 #define KEY_GUI 0xE3 // Convenience
251 #define KEY_LGUI 0xE3
252 #define KEY_RCTRL 0xE4
253 #define KEY_RSHIFT 0xE5
254 #define KEY_RALT 0xE6
255 #define KEY_RGUI 0xE7
256 // 0xE8 - 0xFFFF Reserved
257 // Except for 0xE0-0xE7 which are DV (Dynamic Flags), all Keycodes are Sel (Selectors).
261 // List of LED codes - USB HID 1.12v2 pg 61
262 // LED/Indicators are defined as:
263 // OOC - On/Off Control
264 // US - Usage Indicator: 1 - In Use, 0 - Not In Use
265 // UM - Usage Multi Mode Indicator Collection of 1 or more indicators: On, Flash, Slow Blink, Fast Blink, Off
268 #define LED_UNDEFINED 0x00
269 #define LED_NUM_LOCK 0x01 // OOC
270 #define LED_CAPS_LOCK 0x02 // OOC
271 #define LED_SCROLL_LOCK 0x03 // OOC
272 #define LED_COMPOSE 0x04 // OOC
273 #define LED_KANA 0x05 // OOC
274 #define LED_POWER 0x06 // OOC
275 #define LED_SHIFT 0x07 // OOC
276 #define LED_DO_NOT_DISTURB 0x08 // OOC
277 #define LED_MUTE 0x09 // OOC
278 #define LED_TONE_ENABLE 0x0A // OOC
279 #define LED_HIGHCUT_FILTER 0x0B // OOC
280 #define LED_LOWCUT_FILTER 0x0C // OOC
281 #define LED_EQL_ENABLE 0x0D // OOC
282 #define LED_SND_FLD_ON 0x0E // OOC
283 #define LED_SURROUND_ON 0x0F // OOC
284 #define LED_REPEAT 0x10 // OOC
285 #define LED_STEREO 0x11 // OOC
286 #define LED_SAMPLE_RT_DET 0x12 // OOC
287 #define LED_SPINNING 0x13 // OOC
288 #define LED_CAV 0x14 // OOC
289 #define LED_CLV 0x15 // OOC
290 #define LED_REC_FMT_DET 0x16 // OOC
291 #define LED_OFF_HOOK 0x17 // OOC
292 #define LED_RING 0x18 // OOC
293 #define LED_MSG_WAITING 0x19 // OOC
294 #define LED_DATA_MODE 0x1A // OOC
295 #define LED_BAT_OPERATION 0x1B // OOC
296 #define LED_BAT_OK 0x1C // OOC
297 #define LED_BAT_LOW 0x1D // OOC
298 #define LED_SPEAKER 0x1E // OOC
299 #define LED_HEAD_SET 0x1F // OOC
300 #define LED_HOLD 0x20 // OOC
301 #define LED_MICROPHONE 0x21 // OOC
302 #define LED_COVERAGE 0x22 // OOC
303 #define LED_NIGHT_MODE 0x23 // OOC
304 #define LED_SEND_CALLS 0x24 // OOC
305 #define LED_CALL_PICKUP 0x25 // OOC
306 #define LED_CONFERENCE 0x26 // OOC
307 #define LED_STAND_BY 0x27 // OOC
308 #define LED_CAMERA_ON 0x28 // OOC
309 #define LED_CAMERA_OFF 0x29 // OOC
310 #define LED_ON_LINE 0x2A // OOC
311 #define LED_OFF_LINE 0x2B // OOC
312 #define LED_BUSY 0x2C // OOC
313 #define LED_READY 0x2D // OOC
314 #define LED_PAPER_OUT 0x2E // OOC
315 #define LED_PAPER_JAM 0x2F // OOC
316 #define LED_REMOTE 0x30 // OOC
317 #define LED_FORWARD 0x31 // OOC
318 #define LED_REVERSE 0x32 // OOC
319 #define LED_STOP 0x33 // OOC
320 #define LED_REWIND 0x34 // OOC
321 #define LED_FAST_FORWARD 0x35 // OOC
322 #define LED_PLAY 0x36 // OOC
323 #define LED_PAUSE 0x37 // OOC
324 #define LED_RECORD 0x38 // OOC
325 #define LED_ERROR 0x39 // OOC
326 #define LED_USI 0x3A // US
327 #define LED_UIUI 0x3B // US
328 #define LED_UMMI 0x3C // UM
329 #define LED_IND_ON 0x3D // Sel
330 #define LED_IND_FLASH 0x3E // Sel
331 #define LED_IND_SLOW_BLNK 0x3F // Sel
332 #define LED_IND_FAST_BLNK 0x40 // Sel
333 #define LED_IND_OFF 0x41 // Sel
334 #define LED_FLASH_ON_TIME 0x42 // DV
335 #define LED_SLW_B_ON_TIME 0x43 // DV
336 #define LED_SLW_B_OFF_TIME 0x44 // DV
337 #define LED_FST_B_ON_TIME 0x45 // DV
338 #define LED_FST_B_OFF_TIME 0x46 // DV
339 #define LED_UIC 0x47 // UM
340 #define LED_IND_RED 0x48 // Sel
341 #define LED_IND_GREEN 0x49 // Sel
342 #define LED_IND_AMBER 0x4A // Sel
343 #define LED_GENERIC_IND 0x4B // OOC
344 #define LED_SYS_SUSPEND 0x4C // OOC
345 #define LED_EXT_PWR_CONN 0x4D // OOC
346 // 0x4E - 0xFFFF Reserved
350 // List of Mouse Buttons - USB HID 1.12v2 pg 67
351 #define MOUSE_NOPRESS 0x00
352 #define MOUSE_PRIMARY 0x01 // Button 1
353 #define MOUSE_SECONDARY 0x02 // Button 2
354 #define MOUSE_TERTIARY 0x03 // Button 3
355 #define MOUSE_BUTTON(x) x
356 // Continues to 0xFFFF, the higher the Mouse code, the selector significance descreases
357 // Buttons can be defined as:
359 // OOC - On/Off Control
360 // MC - Momentary Control
361 // OSC - One-Shot Control
362 // depending on context.
366 // List of System Controls - USB HID 1.12v2 pg 32
367 // NKRO HID Supports 0x81 - 0xB7
368 #define SYS_POWER_DOWN 0x81
369 #define SYS_SLEEP 0x82
370 #define SYS_WAKE_UP 0x83
371 #define SYS_CONTEXT_MENU 0x84
372 #define SYS_MAIN_MENU 0x85
373 #define SYS_APP_MENU 0x86
374 #define SYS_MENU_HELP 0x87
375 #define SYS_MENU_EXIT 0x88
376 #define SYS_MENU_SELECT 0x89
377 #define SYS_MENU_RIGHT 0x8A
378 #define SYS_MENU_LEFT 0x8B
379 #define SYS_MENU_UP 0x8C
380 #define SYS_MENU_DOWN 0x8D
381 #define SYS_COLD_RESTART 0x8E
382 #define SYS_WARM_RESTART 0x8F
383 #define SYS_DPAD_UP 0x90
384 #define SYS_DPAD_DOWN 0x91
385 #define SYS_DPAD_RIGHT 0x92
386 #define SYS_DPAD_LEFT 0x93
387 // 0x94 - 0x9F Reserved
388 #define SYS_DOCK 0xA0
389 #define SYS_UNDOCK 0xA1
390 #define SYS_SETUP 0xA2
391 #define SYS_BREAK 0xA3
392 #define SYS_DEBUGGER_BREAK 0xA4
393 #define SYS_APP_BREAK 0xA5
394 #define SYS_APP_DEBUGGER_BREAK 0xA6
395 #define SYS_SPEAKER_MUTE 0xA7
396 #define SYS_HIBERNATE 0xA8
397 // 0xA9 - 0xAF Reserved
398 #define SYS_DISP_INVERT 0xB0
399 #define SYS_DISP_INTERNAL 0xB1
400 #define SYS_DISP_EXTERNAL 0xB2
401 #define SYS_DISP_BOTH 0xB3
402 #define SYS_DISP_DUAL 0xB4
403 #define SYS_DISP_TOGGLE_INT_EXT 0xB5
404 #define SYS_DISP_SWAP_PRI_SEC 0xB6
405 #define SYS_DISP_LCD_AUTOSCALE 0xB7
406 // 0xB8 - 0xFFFF Reserved
410 // List of Consumer Codes - USB HID 1.12v2
411 // Only listing relevant ones, let me know if you need more -HaaTa
412 // NKRO HID Supports 0x020 - 0x29C
413 #define CONSUMER_10 0x020
414 #define CONSUMER_100 0x021
415 #define CONSUMER_AM_PM 0x022
416 // 0x023 - 0x03F Reserved
417 #define CONSUMER_POWER 0x030
418 #define CONSUMER_RESET 0x031
419 #define CONSUMER_SLEEP 0x032
420 #define CONSUMER_SLEEP_AFTER 0x033
421 #define CONSUMER_SLEEP_MODE 0x034
422 #define CONSUMER_ILLUMINATION 0x035
424 // 0x037 - 0x03F Reserved
425 #define CONSUMER_MENU 0x040
426 #define CONSUMER_MENU_PICK 0x041
427 #define CONSUMER_MENU_UP 0x042
428 #define CONSUMER_MENU_DOWN 0x043
429 #define CONSUMER_MENU_LEFT 0x044
430 #define CONSUMER_MENU_RIGHT 0x045
431 #define CONSUMER_MENU_ESCAPE 0x046
432 #define CONSUMER_MENU_VALUE_INCREASE 0x047
433 #define CONSUMER_MENU_VALUE_DECREASE 0x048
434 // 0x049 - 0x05F Reserved
435 #define CONSUMER_DATA_ON_SCREEN 0x060
436 #define CONSUMER_CLOSED_CAPTION 0x061
437 #define CONSUMER_CLOSED_CAPTION_SELECT 0x062
438 #define CONSUMER_VCR_TV 0x063
439 #define CONSUMER_BROADCAST_MODE 0x064
440 #define CONSUMER_SNAPSHOT 0x065
441 #define CONSUMER_STILL 0x066
442 // 0x067 - 0x07F Reserved
444 #define CONSUMER_ASSIGN_SELECTION 0x081
445 #define CONSUMER_MODE_STEP 0x082
446 #define CONSUMER_RECALL_LAST 0x083
447 #define CONSUMER_ENTER_CHANNEL 0x084
448 #define CONSUMER_ORDER_MOVIE 0x085
450 #define CONSUMER_MEDIA_COMPUTER 0x088
451 #define CONSUMER_MEDIA_TV 0x089
452 #define CONSUMER_MEDIA_WWW 0x08A
453 #define CONSUMER_MEDIA_DVD 0x08B
454 #define CONSUMER_MEDIA_TELEPHONE 0x08C
455 #define CONSUMER_MEDIA_PROGRAM_GUIDE 0x08D
456 #define CONSUMER_MEDIA_VIDEO_PHONE 0x08E
457 #define CONSUMER_MEDIA_SELECT_GAMES 0x08F
458 #define CONSUMER_MEDIA_SELECT_MESSAGES 0x090
459 #define CONSUMER_MEDIA_SELECT_CD 0x091
460 #define CONSUMER_MEDIA_SELECT_VCR 0x092
461 #define CONSUMER_MEDIA_SELECT_TUNER 0x093
462 #define CONSUMER_QUIT 0x094
463 #define CONSUMER_HELP 0x095
464 #define CONSUMER_MEDIA_SELECT_TAPE 0x096
465 #define CONSUMER_MEDIA_SELECT_CABLE 0x097
466 #define CONSUMER_MEDIA_SELECT_SATELLITE 0x098
467 #define CONSUMER_MEDIA_SELECT_SECURITY 0x099
468 #define CONSUMER_MEDIA_SELECT_HOME 0x09A
469 #define CONSUMER_MEDIA_SELECT_CALL 0x09B
470 #define CONSUMER_CHANNEL_INCREMENT 0x09C
471 #define CONSUMER_CAHNNEL_DECREMENT 0x09D
472 #define CONSUMER_MEDIA_SELECT_SAP 0x09E
474 #define CONSUMER_VCR_PLUS 0x0A0
475 #define CONSUMER_ONCE 0x0A1
476 #define CONSUMER_DAILY 0x0A2
477 #define CONSUMER_WEEKLY 0x0A3
478 #define CONSUMER_MONTHLY 0x0A4
479 // 0x0A5 - 0x0AF Reserved
480 #define CONSUMER_PLAY 0x0B0
481 #define CONSUMER_PAUSE 0x0B1
482 #define CONSUMER_RECORD 0x0B2
483 #define CONSUMER_FAST_FORWARD 0x0B3
484 #define CONSUMER_REWIND 0x0B4
485 #define CONSUMER_SCAN_NEXT_TRACK 0x0B5
486 #define CONSUMER_SCAN_PREVIOUS_TRACK 0x0B6
487 #define CONSUMER_STOP 0x0B7
488 #define CONSUMER_EJECT 0x0B8
489 #define CONSUMER_RANDOM_PLAY 0x0B9
491 #define CONSUMER_REPEAT 0x0BC
493 #define CONSUMER_TRACK_NORMAL 0x0BE
495 #define CONSUMER_FRAME_FORWARD 0x0C0
496 #define CONSUMER_FRAME_BACK 0x0C1
497 #define CONSUMER_MARK 0x0C2
498 #define CONSUMER_CLEAR_MARK 0x0C3
499 #define CONSUMER_REPEAT_FROM_MARK 0x0C4
500 #define CONSUMER_RETURN_TO_MARK 0x0C5
501 #define CONSUMER_SEARCH_MARK_FORWARDS 0x0C6
502 #define CONSUMER_SEARCH_MARK_BACKWARDS 0x0C7
503 #define CONSUMER_COUNTER_RESET 0x0C8
504 #define CONSUMER_SHOW_COUNTER 0x0C9
505 #define CONSUMER_TRACKING_INCREMENT 0x0CA
506 #define CONSUMER_TRACKING_DECREMENT 0x0CB
507 #define CONSUMER_STOP_EJECT 0x0CC
508 #define CONSUMER_PAUSE_PLAY 0x0CD
509 #define CONSUMER_PLAY_SKIP 0x0CE
510 // 0x0CF - 0x0DF Reserved
512 #define CONSUMER_MUTE 0x0E2
514 #define CONSUMER_BASS_BOOST 0x0E5
515 #define CONSUMER_SURROUND_MODE 0x0E6
516 #define CONSUMER_LOUDNESS 0x0E7
517 #define CONSUMER_MPX 0x0E8
518 #define CONSUMER_VOLUME_UP 0x0E9
519 #define CONSUMER_VOLUME_DOWN 0x0EA
520 // 0x0EB - 0x0EF Reserved
521 #define CONSUMER_SPEED_SELECT 0x0F0
522 #define CONSUMER_STANDARD_PLAY 0x0F2
523 #define CONSUMER_LONG_PLAY 0x0F3
524 #define CONSUMER_EXTENDED_PLAY 0x0F4
525 #define CONSUMER_SLOW 0x0F5
527 #define CONSUMER_FAN_ENABLE 0x100
529 #define CONSUMER_LIGHT_ENABLE 0x102
531 #define CONSUMER_CLIMATE_CONTROL_ENABLE 0x104
533 #define CONSUMER_SECURITY_ENABLE 0x106
534 #define CONSUMER_FIRE_ALARM 0x107
536 #define CONSUMER_MOTION 0x10A
537 #define CONSUMER_DURESS_ALARM 0x10B
538 #define CONSUMER_HOLDUP_ALARM 0x10C
539 #define CONSUMER_MEDICAL_ALARM 0x10D
540 // 0x10E - 0x14F Reserved
541 #define CONSUMER_BALANCE_RIGHT 0x150
542 #define CONSUMER_BALANCE_LEFT 0x151
543 #define CONSUMER_BASS_INCR 0x152
544 #define CONSUMER_BASS_DECR 0x153
545 #define CONSUMER_TREBLE_INCR 0x154
546 #define CONSUMER_TREBLE_DECR 0x155
547 // 0x156 - 0x15F Reserved
549 #define CONSUMER_SUB_CHANNEL_INCREMENT 0x171
550 #define CONSUMER_SUB_CHANNEL_DECREMENT 0x172
551 #define CONSUMER_ALT_AUDIO_INCREMENT 0x173
552 #define CONSUMER_ALT_AUDIO_DECREMENT 0x174
556 // List of Consumer Codes - USB HID 1.12v2
557 // Application Launch Buttons pg 79
558 #define AL_LAUNCH_BUTTON_CONFIG_TOOL 0x181
559 #define AL_PROGRAMMABLE_BUTTON_CONFIG 0x182
560 #define AL_CONSUMER_CONTROL_CONFIG 0x183
561 #define AL_WORD_PROCESSOR 0x184
562 #define AL_TEXT_EDITOR 0x185
563 #define AL_SPREADSHEET 0x186
564 #define AL_GRAPHICS_EDITOR 0x187
565 #define AL_PRESENTATION_APP 0x188
566 #define AL_DATABASE_APP 0x189
567 #define AL_EMAIL_READER 0x18A
568 #define AL_NEWSREADER 0x18B
569 #define AL_VOICEMAIL 0x18C
570 #define AL_CONTACTS_ADDRESS_BOOK 0x18D
571 #define AL_CALENDAR_SCHEDULE 0x18E
572 #define AL_TASK_PROJECT_MANAGER 0x18F
573 #define AL_LOG_JOURNAL_TIMECARD 0x190
574 #define AL_CHECKBOOK_FINANCE 0x191
575 #define AL_CALCULATOR 0x192
576 #define AL_A_V_CAPTURE_PLAYBACK 0x193
577 #define AL_LOCAL_MACHINE_BROWSER 0x194
578 #define AL_LAN_WAN_BROWSER 0x195
579 #define AL_INTERNET_BROWSER 0x196
580 #define AL_REMOTE_NETWORKING_ISP_CONNECT 0x197
581 #define AL_NETWORK_CONFERENCE 0x198
582 #define AL_NETWORK_CHAT 0x199
583 #define AL_TELEPHONY_DIALER 0x19A
584 #define AL_LOGON 0x19B
585 #define AL_LOGOFF 0x19C
586 #define AL_LOGON_LOGOFF 0x19D
587 #define AL_TERMINAL_LOCK_SCREENSAVER 0x19E
588 #define AL_CONTROL_PANEL 0x19F
589 #define AL_COMMAND_LINE_PROCESSOR_RUN 0x1A0
590 #define AL_PROCESS_TASK_MANAGER 0x1A1
591 #define AL_SELECT_TAST_APP 0x1A2
592 #define AL_NEXT_TASK_APP 0x1A3
593 #define AL_PREVIOUS_TASK_APP 0x1A4
594 #define AL_PREEMPTIVE_HALT_TASK_APP 0x1A5
595 #define AL_INTEGRATED_HELP_CENTER 0x1A6
596 #define AL_DOCUMENTS 0x1A7
597 #define AL_THESAURUS 0x1A8
598 #define AL_DICTIONARY 0x1A9
599 #define AL_DESKTOP 0x1AA
600 #define AL_SPELL_CHECK 0x1AB
601 #define AL_GRAMMAR_CHECK 0x1AC
602 #define AL_WIRELESS_STATUS 0x1AD
603 #define AL_KEYBOARD_LAYOUT 0x1AE
604 #define AL_VIRUS_PROTECTION 0x1AF
605 #define AL_ENCRYPTION 0x1B0
606 #define AL_SCREEN_SAVER 0x1B1
607 #define AL_ALARMS 0x1B2
608 #define AL_CLOCK 0x1B3
609 #define AL_FILE_BROWSER 0x1B4
610 #define AL_POWER_STATUS 0x1B5
611 #define AL_IMAGE_BROWSER 0x1B6
612 #define AL_AUDIO_BROWSER 0x1B7
613 #define AL_MOVIE_BROWSER 0x1B8
614 #define AL_DIGITAL_RIGHTS_MANAGER 0x1B9
615 #define AL_DIGITAL_WALLET 0x1BA
617 #define AL_INSTANT_MESSAGING 0x1BC
618 #define AL_OEM_FEATURES_TIPS_TUTORIAL 0x1BD
619 #define AL_OEM_HELP 0x1BE
620 #define AL_ONLINE_COMMUNITY 0x1BF
621 #define AL_ENTERTAINMENT_CONTENT 0x1C0
622 #define AL_ONLINE_SHOPPING 0x1C1
623 #define AL_SMARTCARD_INFO_HELP 0x1C2
624 #define AL_MARKET_MONITOR 0x1C3
625 #define AL_CUSTOMIZED_CORP_NEWS 0x1C4
626 #define AL_ONLINE_ACTIVITY 0x1C5
627 #define AL_SEARCH_BROWSER 0x1C6
628 #define AL_AUDIO_PLAYER 0x1C7
632 // List of Consumer Codes - USB HID 1.12v2
633 // Generic GUI Application Controls pg 82
635 #define AC_OPEN 0x202
636 #define AC_CLOSE 0x203
637 #define AC_EXIT 0x204
638 #define AC_MAXIMIZE 0x205
639 #define AC_MINIMIZE 0x206
640 #define AC_SAVE 0x207
641 #define AC_PRINT 0x208
642 #define AC_PROPERTIES 0x209
643 #define AC_UNDO 0x21A
644 #define AC_COPY 0x21B
646 #define AC_PASTE 0x21D
647 #define AC_SELECT_ALL 0x21E
648 #define AC_FIND 0x21F
649 #define AC_FIND_AND_REPLACE 0x220
650 #define AC_SEARCH 0x221
651 #define AC_GO_TO 0x222
652 #define AC_HOME 0x223
653 #define AC_BACK 0x224
654 #define AC_FORWARD 0x225
655 #define AC_STOP 0x226
656 #define AC_REFRESH 0x227
657 #define AC_PREVIOUS_LINK 0x228
658 #define AC_NEXT_LINK 0x229
659 #define AC_BOOKMARKS 0x22A
660 #define AC_HISTORY 0x22B
661 #define AC_SUBSCRIPTIONS 0x22C
662 #define AC_ZOOM_IN 0x22D
663 #define AC_ZOOM_OUT 0x22E
664 #define AC_ZOOM 0x22F
665 #define AC_FULL_SCREEN_VIEW 0x230
666 #define AC_NORMAL_VIEW 0x231
667 #define AC_VIEW_TOGGLE 0x232
668 #define AC_SCROLL_UP 0x233
669 #define AC_SCROLL_DOWN 0x234
670 #define AC_SCROLL 0x235
671 #define AC_PAN_LEFT 0x236
672 #define AC_PAN_RIGHT 0x237
674 #define AC_NEW_WINDOW 0x239
675 #define AC_TILE_HORIZONTALLY 0x23A
676 #define AC_TILE_VERTICALLY 0x23B
677 #define AC_FORMAT 0x23C
678 #define AC_EDIT 0x23D
679 #define AC_BOLD 0x23E
680 #define AC_ITALICS 0x23F
681 #define AC_UNDERLINE 0x240
682 #define AC_STRIKETHROUGH 0x241
683 #define AC_SUBSCRIPT 0x242
684 #define AC_SUPERSCRIPT 0x243
685 #define AC_ALL_CAPS 0x244
686 #define AC_ROTATE 0x245
687 #define AC_RESIZE 0x246
688 #define AC_FILP_HORIZONTAL 0x247
689 #define AC_FILP_VERTICAL 0x248
690 #define AC_MIRROR_HORIZONTAL 0x249
691 #define AC_MIRROR_VERTICAL 0x24A
692 #define AC_FONT_SELECT 0x24B
693 #define AC_FONT_COLOR 0x24C
694 #define AC_FONT_SIZE 0x24D
695 #define AC_JUSTIFY_LEFT 0x24E
696 #define AC_JUSTIFY_CENTER_H 0x24F
697 #define AC_JUSTIFY_RIGHT 0x250
698 #define AC_JUSTIFY_BLOCK_H 0x251
699 #define AC_JUSTIFY_TOP 0x252
700 #define AC_JUSTIFY_CENTER_V 0x253
701 #define AC_JUSTIFY_BOTTOM 0x254
702 #define AC_JUSTIFY_BLOCK_V 0x255
703 #define AC_INDENT_DECREASE 0x256
704 #define AC_INDENT_INCREASE 0x257
705 #define AC_NUMBERED_LIST 0x258
706 #define AC_RESTART_NUMBERING 0x259
707 #define AC_BULLETED_LIST 0x25A
708 #define AC_PROMOTE 0x25B
709 #define AC_DEMOTE 0x25C
712 #define AC_CANCEL 0x25F
713 #define AC_CATALOG 0x260
714 #define AC_BUY_CHECKOUT 0x261
715 #define AC_ADD_TO_CART 0x262
716 #define AC_EXPAND 0x263
717 #define AC_EXPAND_ALL 0x264
718 #define AC_COLLAPSE 0x265
719 #define AC_COLLAPSE_ALL 0x266
720 #define AC_PRINT_PREVIEW 0x267
721 #define AC_PASTE_SPECIAL 0x268
722 #define AC_INSERT_MODE 0x269
723 #define AC_DELETE 0x26A
724 #define AC_LOCK 0x26B
725 #define AC_UNLOCK 0x26C
726 #define AC_PROTECT 0x26D
727 #define AC_UNPROTECT 0x26E
728 #define AC_ATTACH_COMMENT 0x26F
729 #define AC_DELETE_COMMENT 0x270
730 #define AC_VIEW_COMMENT 0x271
731 #define AC_SELECT_WORD 0x272
732 #define AC_SELECT_SENTENCE 0x273
733 #define AC_SELECT_PARAGRAPH 0x274
734 #define AC_SELECT_COLUMN 0x275
735 #define AC_SELECT_ROW 0x276
736 #define AC_SELECT_TABLE 0x277
737 #define AC_SELECT_OBJECT 0x278
738 #define AC_REDO_REPEAT 0x279
739 #define AC_SORT 0x27A
740 #define AC_SORT_ASCENDING 0x27B
741 #define AC_SORT_DESCENDING 0x27C
742 #define AC_FILTER 0x27D
743 #define AC_SET_CLOCK 0x27E
744 #define AC_VIEW_CLOCK 0x27F
745 #define AC_SELECT_TIME_ZONE 0x280
746 #define AC_EDIT_TIME_ZONE 0x281
747 #define AC_SET_ALARM 0x282
748 #define AC_CLEAR_ALARM 0x283
749 #define AC_SNOOZE_ALARM 0x284
750 #define AC_RESET_ALARM 0x285
751 #define AC_SYNCHRONIZE 0x286
752 #define AC_SEND_RECEIVE 0x287
753 #define AC_SEND_TO 0x288
754 #define AC_REPLY 0x289
755 #define AC_REPLY_ALL 0x28A
756 #define AC_FORWARD_MSG 0x28B
757 #define AC_SEND 0x28C
758 #define AC_ATTACH_FILE 0x28D
759 #define AC_UPLOAD 0x28E
760 #define AC_DOWNLOAD 0x28F
761 #define AC_SET_BORDERS 0x290
762 #define AC_INSERT_ROW 0x291
763 #define AC_INSERT_COLUMN 0x292
764 #define AC_INSERT_FILE 0x293
765 #define AC_INSERT_PICTURE 0x294
766 #define AC_INSERT_OBJECT 0x295
767 #define AC_INSERT_SYMBOL 0x296
768 #define AC_SAVE_AND_CLOSE 0x297
769 #define AC_RENAME 0x298
770 #define AC_MERGE 0x299
771 #define AC_SPLIT 0x29A
772 #define AC_DISTRIBUTE_HORIZONTALLY 0x29B
773 #define AC_DISTRIBUTE_VERTICALLY 0x29C
774 // 0x29D-0xFFFF Reserved