diff options
author | Drashna Jaelre <drashna@live.com> | 2022-06-08 18:39:16 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-08 18:39:16 -0700 |
commit | 0ab51ee29d6e980a50b27f122a10d0f7de4b1aed (patch) | |
tree | 8e4d62aa24feccfd8f9c51bf64b1fc7391ff0534 /tmk_core/protocol/vusb | |
parent | 84944df6a635da6502117e5b245113296babb39e (diff) |
Add support for large Mouse Reports (#16371)
Co-authored-by: Sergey Vlasov <sigprof@gmail.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'tmk_core/protocol/vusb')
-rw-r--r-- | tmk_core/protocol/vusb/vusb.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/tmk_core/protocol/vusb/vusb.c b/tmk_core/protocol/vusb/vusb.c index ebde955d3b..d07cc0d27e 100644 --- a/tmk_core/protocol/vusb/vusb.c +++ b/tmk_core/protocol/vusb/vusb.c @@ -482,14 +482,28 @@ const PROGMEM uchar shared_hid_report[] = { 0x75, 0x01, // Report Size (1) 0x81, 0x02, // Input (Data, Variable, Absolute) - // X/Y position (2 bytes) +# ifdef MOUSE_EXTENDED_REPORT + // Boot protocol XY ignored in Report protocol + 0x95, 0x02, // Report Count (2) + 0x75, 0x08, // Report Size (8) + 0x81, 0x03, // Input (Constant) +# endif + + // X/Y position (2 or 4 bytes) 0x05, 0x01, // Usage Page (Generic Desktop) 0x09, 0x30, // Usage (X) 0x09, 0x31, // Usage (Y) +# ifndef MOUSE_EXTENDED_REPORT 0x15, 0x81, // Logical Minimum (-127) 0x25, 0x7F, // Logical Maximum (127) 0x95, 0x02, // Report Count (2) 0x75, 0x08, // Report Size (8) +# else + 0x16, 0x01, 0x80, // Logical Minimum (-32767) + 0x26, 0xFF, 0x7F, // Logical Maximum (32767) + 0x95, 0x02, // Report Count (2) + 0x75, 0x10, // Report Size (16) +# endif 0x81, 0x06, // Input (Data, Variable, Relative) // Vertical wheel (1 byte) |