hid_read only reads two bytes #716
Unanswered
microhenrio
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've been using hidapi to send from an RPI to a custom board with an STM32 microcontroller without problem. But when trying to receive hid_read only returns two bytes. I've checked the sent data with wireshark and seems correct, all the data is in the data frame.
I've tried with different sizes of frames, using hid_read_timeout, enabling nonblock, etc.. Always reads two byes, normally the first two but sometimes others from the data frame.
The part of the descriptor in the microcontroller used to send to the RPI is like this:
I'm using hidapi 0.13.1 ina and RPI with Raspian 12, kernel 6.6.72-v8+, but I've tried in an Ubuntu with the same behavior.
The packet captured in the wireshark shows all the data (Descriptor ID + 12 bytes):
Beta Was this translation helpful? Give feedback.
All reactions