For those interested, the issue was on the HID descriptor, or rather the fact that for some reason the 'feature report' was not liked by hidapi, and I've changed it to an "output report" as follows, now both machines can communicate.
Still, I have s mall issue in which if the report is not read promptly on the RPI, the PC will get stuck until it is read. Not sure why.
Still, I have s mall issue in which if the report is not read promptly on the RPI, the PC will get stuck until it is read. Not sure why.
Code:
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)0x09, 0x04, // Usage (Joystick)0xA1, 0x01, // Collection (Application)0x09, 0x04, // Usage (Joystick)0xA1, 0x02, // Collection (Logical)0x05, 0x09, // Usage Page (Button)0x85, 0x01, // Report ID (1)0x19, 0x01, // Usage Minimum (0x01)0x29, 0x18, // Usage Maximum (0x18)0x15, 0x00, // Logical Minimum (0)0x25, 0x01, // Logical Maximum (1)0x75, 0x01, // Report Size (1)0x95, 0x18, // Report Count (24)0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)0x06, 0x00, 0xFF, // Usage Page (Vendor Defined 0xFF00)0x09, 0x01, // Usage (0x01)0x85, 0x02, // Report ID (2)0x15, 0x00, // Logical Minimum (0)0x26, 0xFF, 0x00, // Logical Maximum (255)0x75, 0x08, // Report Size (8)0x95, 0x10, // Report Count (16)0x91, 0x02, // Output (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) <== HERE0xC0, // End Collection0xC0, // End Collection// 48 bytes
Statistics: Posted by kiro — Fri Apr 12, 2024 8:31 am