Disable reportId for now cause it breaks output
Signed-off-by: fly <merspieler@alwaysdata.com>
This commit is contained in:
parent
6c3fe969dd
commit
55f6b22f7d
2 changed files with 5 additions and 5 deletions
|
@ -19,7 +19,7 @@ pub const CUSTOM_DESCRIPTOR: &[u8] = &[
|
||||||
0x05, 0x01, // UsagePage(Generic Desktop[0x0001])
|
0x05, 0x01, // UsagePage(Generic Desktop[0x0001])
|
||||||
0x09, 0x04, // UsageId(Joystick[0x0004])
|
0x09, 0x04, // UsageId(Joystick[0x0004])
|
||||||
0xA1, 0x01, // Collection(Application)
|
0xA1, 0x01, // Collection(Application)
|
||||||
0x85, 0x01, // ReportId(1)
|
// 0x85, 0x01, // ReportId(1)
|
||||||
0x09, 0x01, // UsageId(Pointer[0x0001])
|
0x09, 0x01, // UsageId(Pointer[0x0001])
|
||||||
0xA1, 0x00, // Collection(Physical)
|
0xA1, 0x00, // Collection(Physical)
|
||||||
0x09, 0x30, // UsageId(X[0x0030])
|
0x09, 0x30, // UsageId(X[0x0030])
|
||||||
|
@ -50,10 +50,10 @@ pub const CUSTOM_DESCRIPTOR: &[u8] = &[
|
||||||
];
|
];
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Eq, PartialEq, Default, PackedStruct)]
|
#[derive(Clone, Copy, Debug, Eq, PartialEq, Default, PackedStruct)]
|
||||||
#[packed_struct(endian = "lsb", size_bytes = "8")]
|
#[packed_struct(endian = "lsb", size_bytes = "6")]
|
||||||
pub struct CustomInputReport {
|
pub struct CustomInputReport {
|
||||||
#[packed_field]
|
// #[packed_field]
|
||||||
pub report_id: u8,
|
// pub report_id: u8,
|
||||||
#[packed_field]
|
#[packed_field]
|
||||||
pub axis: [u16; 2],
|
pub axis: [u16; 2],
|
||||||
#[packed_field]
|
#[packed_field]
|
||||||
|
|
|
@ -257,7 +257,7 @@ fn get_report(pins: &mut MyPins, adc1: &mut adc::Adc<pac::ADC1>, cal: &Calibrati
|
||||||
}
|
}
|
||||||
|
|
||||||
CustomInputReport {
|
CustomInputReport {
|
||||||
report_id: 1,
|
// report_id: 1,
|
||||||
axis: values_norm,
|
axis: values_norm,
|
||||||
buttons,
|
buttons,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue