Fixed USB Error in MCDU firmware

Signed-off-by: fly <merspieler@alwaysdata.net>
This commit is contained in:
fly 2024-10-09 16:31:13 +02:00
parent 0e29f0aa9c
commit df0d0b95d5
2 changed files with 11 additions and 3 deletions

View file

@ -4,7 +4,11 @@ usage = ['Generic Desktop', 'Joystick']
[[applicationCollection.inputReport]]
[[applicationCollection.inputReport.variableItem]]
usageRange = ['Button', 'Button 1', 'Button 96']
usageRange = ['Button', 'Button 1', 'Button 64']
logicalValueRange = [0, 1]
[[applicationCollection.inputReport.variableItem]]
usageRange = ['Button', 'Button 1', 'Button 32']
logicalValueRange = [0, 1]
[[applicationCollection.outputReport]]

View file

@ -22,12 +22,16 @@ pub const CUSTOM_DESCRIPTOR: &[u8] = &[
0x85, 0x01, // ReportId(1)
0x05, 0x09, // UsagePage(Button[0x0009])
0x19, 0x01, // UsageIdMin(Button 1[0x0001])
0x29, 0x60, // UsageIdMax(Button 96[0x0060])
0x29, 0x40, // UsageIdMax(Button 64[0x0040])
0x15, 0x00, // LogicalMinimum(0)
0x25, 0x01, // LogicalMaximum(1)
0x95, 0x60, // ReportCount(96)
0x95, 0x40, // ReportCount(64)
0x75, 0x01, // ReportSize(1)
0x81, 0x02, // Input(Data, Variable, Absolute, NoWrap, Linear, PreferredState, NoNullPosition, BitField)
0x19, 0x01, // UsageIdMin(Button 1[0x0001])
0x29, 0x20, // UsageIdMax(Button 32[0x0020])
0x95, 0x20, // ReportCount(32)
0x81, 0x02, // Input(Data, Variable, Absolute, NoWrap, Linear, PreferredState, NoNullPosition, BitField)
0x05, 0x0E, // UsagePage(Haptics[0x000E])
0x09, 0x21, // UsageId(Manual Trigger[0x0021])
0x25, 0x7F, // LogicalMaximum(127)