cli: read hid reports
This commit is contained in:
@@ -3,4 +3,5 @@ name = "shared"
|
||||
edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
deku = { version = "0.20.3", default-features = false }
|
||||
usbd-hid = { version = "0.10.0" }
|
||||
|
||||
+11
-8
@@ -1,17 +1,20 @@
|
||||
#![no_std]
|
||||
|
||||
pub mod hid {
|
||||
use deku::DekuRead;
|
||||
use usbd_hid::descriptor::generator_prelude::*;
|
||||
|
||||
#[derive(DekuRead)]
|
||||
#[deku(endian = "little")]
|
||||
#[gen_hid_descriptor(
|
||||
(collection = APPLICATION, usage_page = VENDOR_DEFINED_START, usage = 0x01, ) = {
|
||||
average_buffer_fill=input;
|
||||
frame_count=input;
|
||||
dac_underflow_count=input;
|
||||
usb_underflow_count=input;
|
||||
dac_overflow_count=input;
|
||||
}
|
||||
)]
|
||||
(collection = APPLICATION, usage_page = VENDOR_DEFINED_START, usage = 0x01, ) = {
|
||||
average_buffer_fill=input;
|
||||
frame_count=input;
|
||||
dac_underflow_count=input;
|
||||
usb_underflow_count=input;
|
||||
dac_overflow_count=input;
|
||||
}
|
||||
)]
|
||||
#[repr(C)]
|
||||
// Note these are all actually u32
|
||||
pub struct AudioTelemetryReport {
|
||||
|
||||
Reference in New Issue
Block a user