receiver: add and remove some HID Consumer Codes to conform with Linux usage
This commit is contained in:
parent
3e6c92de70
commit
4c7f8c831b
|
@ -1042,7 +1042,6 @@ class MRKeyLED(_Setting):
|
|||
return b'\x00'
|
||||
|
||||
|
||||
|
||||
## Only implemented for devices that can produce HID and Consumer Key Codes
|
||||
## Only interested in current host, so use 0xFF for it
|
||||
class PersistentRemappableAction(_Settings):
|
||||
|
@ -1118,7 +1117,7 @@ SETTINGS = [
|
|||
CrownSmooth, # working
|
||||
DivertGkeys, # working
|
||||
MKeyLEDs, # working
|
||||
MRKeyLED, # working
|
||||
MRKeyLED, # working
|
||||
Multiplatform, # working
|
||||
DualPlatform, # simple
|
||||
ChangeHost, # working
|
||||
|
|
|
@ -626,6 +626,7 @@ MOUSE_BUTTONS = _NamedInts(
|
|||
MOUSE_BUTTONS._fallback = lambda x: 'unknown:%02X' % x
|
||||
|
||||
# HID USB Keycodes from https://www.usb.org/sites/default/files/documents/hut1_12v2.pdf
|
||||
# Modified by information from Linux HID driver linux/drivers/hid/hid-input.c
|
||||
USB_HID_KEYCODES = _NamedInts(
|
||||
A=0x04,
|
||||
B=0x05,
|
||||
|
@ -820,14 +821,14 @@ for val, name in modifiers.items():
|
|||
KEYS[0x01000000 + (int(key) << 8) + val] = name + str(key)
|
||||
|
||||
HID_CONSUMERCODES = _NamedInts(
|
||||
Unassigned=0x00,
|
||||
Consumer_Control=0x01,
|
||||
Numeric_Key_Pad=0x02,
|
||||
Programmable_Buttons=0x03,
|
||||
Microphone=0x04,
|
||||
Headphone=0x05,
|
||||
Graphic_Equalizer=0x06,
|
||||
AM__PM=0x22,
|
||||
# Unassigned=0x00,
|
||||
# Consumer_Control=0x01,
|
||||
# Numeric_Key_Pad=0x02,
|
||||
# Programmable_Buttons=0x03,
|
||||
# Microphone=0x04,
|
||||
# Headphone=0x05,
|
||||
# Graphic_Equalizer=0x06,
|
||||
# AM__PM=0x22,
|
||||
Power=0x30,
|
||||
Reset=0x31,
|
||||
Sleep=0x32,
|
||||
|
@ -846,19 +847,33 @@ HID_CONSUMERCODES = _NamedInts(
|
|||
Menu_Value_Decrease=0x48,
|
||||
Data_On_Screen=0x60,
|
||||
Closed_Caption=0x61,
|
||||
Closed_Caption_Select=0x62,
|
||||
# Closed_Caption_Select=0x62,
|
||||
VCR__TV=0x63,
|
||||
Broadcast_Mode=0x64,
|
||||
# Broadcast_Mode=0x64,
|
||||
Snapshot=0x65,
|
||||
Still=0x66,
|
||||
Selection=0x80,
|
||||
Assign_Selection=0x81,
|
||||
# Still=0x66,
|
||||
Red=0x69,
|
||||
Green=0x6A,
|
||||
Blue=0x6B,
|
||||
Yellow=0x6C,
|
||||
Aspect_Ratio=0x6D,
|
||||
Brightness_Up=0x6F,
|
||||
Brightness_Down=0x70,
|
||||
Brightness_Toggle=0x72,
|
||||
Brightness_Min=0x73,
|
||||
Brightness_Max=0x74,
|
||||
Brightness_Auto=0x75,
|
||||
Keyboard_Illumination_Up=0x79,
|
||||
Keyboard_Illumination_Down=0x7A,
|
||||
Keyboard_Illumination_Toggle=0x7C,
|
||||
# Selection=0x80,
|
||||
# Assign_Selection=0x81,
|
||||
Mode_Step=0x82,
|
||||
Recall_Last=0x83,
|
||||
Enter_Channel=0x84,
|
||||
Order_Movie=0x85,
|
||||
Channel=0x86,
|
||||
Media_Selection=0x87,
|
||||
# Order_Movie=0x85,
|
||||
# Channel=0x86,
|
||||
# Media_Selection=0x87,
|
||||
Media_Select_Computer=0x88,
|
||||
Media_Select_TV=0x89,
|
||||
Media_Select_WWW=0x8A,
|
||||
|
@ -878,15 +893,15 @@ HID_CONSUMERCODES = _NamedInts(
|
|||
Media_Select_Satellite=0x98,
|
||||
Media_Select_Security=0x99,
|
||||
Media_Select_Home=0x9A,
|
||||
Media_Select_Call=0x9B,
|
||||
# Media_Select_Call=0x9B,
|
||||
Channel_Increment=0x9C,
|
||||
Channel_Decrement=0x9D,
|
||||
Media_Select_SAP=0x9E,
|
||||
# Media_Select_SAP=0x9E,
|
||||
VCR_Plus=0xA0,
|
||||
Once=0xA1,
|
||||
Daily=0xA2,
|
||||
Weekly=0xA3,
|
||||
Monthly=0xA4,
|
||||
# Once=0xA1,
|
||||
# Daily=0xA2,
|
||||
# Weekly=0xA3,
|
||||
# Monthly=0xA4,
|
||||
Play=0xB0,
|
||||
Pause=0xB1,
|
||||
Record=0xB2,
|
||||
|
@ -903,37 +918,37 @@ HID_CONSUMERCODES = _NamedInts(
|
|||
Tracking=0xBD,
|
||||
Track_Normal=0xBE,
|
||||
Slow_Tracking=0xBF,
|
||||
Frame_Forward=0xC0,
|
||||
Frame_Back=0xC1,
|
||||
Mark=0xC2,
|
||||
Clear_Mark=0xC3,
|
||||
Repeat_From_Mark=0xC4,
|
||||
Return_To_Mark=0xC5,
|
||||
Search_Mark_Forward=0xC6,
|
||||
Search_Mark_Backwards=0xC7,
|
||||
Counter_Reset=0xC8,
|
||||
Show_Counter=0xC9,
|
||||
Tracking_Increment=0xCA,
|
||||
Tracking_Decrement=0xCB,
|
||||
Stop__Eject=0xCC,
|
||||
# Frame_Forward=0xC0,
|
||||
# Frame_Back=0xC1,
|
||||
# Mark=0xC2,
|
||||
# Clear_Mark=0xC3,
|
||||
# Repeat_From_Mark=0xC4,
|
||||
# Return_To_Mark=0xC5,
|
||||
# Search_Mark_Forward=0xC6,
|
||||
# Search_Mark_Backwards=0xC7,
|
||||
# Counter_Reset=0xC8,
|
||||
# Show_Counter=0xC9,
|
||||
# Tracking_Increment=0xCA,
|
||||
# Tracking_Decrement=0xCB,
|
||||
# Stop__Eject=0xCC,
|
||||
Play__Pause=0xCD,
|
||||
Play__Skip=0xCE,
|
||||
# Play__Skip=0xCE,
|
||||
Volume=0xE0,
|
||||
Balance=0xE1,
|
||||
# Balance=0xE1,
|
||||
Mute=0xE2,
|
||||
Bass=0xE3,
|
||||
Treble=0xE4,
|
||||
# Bass=0xE3,
|
||||
# Treble=0xE4,
|
||||
Bass_Boost=0xE5,
|
||||
Surround_Mode=0xE6,
|
||||
Loudness=0xE7,
|
||||
MPX=0xE8,
|
||||
# Surround_Mode=0xE6,
|
||||
# Loudness=0xE7,
|
||||
# MPX=0xE8,
|
||||
Volume_Up=0xE9,
|
||||
Volume_Down=0xEA,
|
||||
Speed_Select=0xF0,
|
||||
Playback_Speed=0xF1,
|
||||
Standard_Play=0xF2,
|
||||
Long_Play=0xF3,
|
||||
Extended_Play=0xF4,
|
||||
# Speed_Select=0xF0,
|
||||
# Playback_Speed=0xF1,
|
||||
# Standard_Play=0xF2,
|
||||
# Long_Play=0xF3,
|
||||
# Extended_Play=0xF4,
|
||||
Slow=0xF5,
|
||||
Fan_Enable=0x100,
|
||||
Fan_Speed=0x101,
|
||||
|
|
Loading…
Reference in New Issue