You can have a look at 5.6 Reports on page 17 of the HID specification for more details. (a mouse event would send a Report ID of 01) So you send a Report ID of 02 before the actual keyboard report. So what you see is the fact that your keyboard only sends keys, and does not need a Report ID whereas your Arduino posing as an HID device has more capabilities and the spec states that it needs to send a report ID before the data. This Report ID is a 1-byte identification prefix to each report transfer. If you can have different types of Reports from a single endpoint, for example your arduino can send both mouse events and keyboard events over the same USB physical connexion, the specification mentions that a Report ID item has to be added in the communication to indicate which data fields are represented in each report structure. To keep it simple, what is sent on the USB bus when an HID device wants to send information is called a Report, defined in a report descriptor (specific to your device). HID is an abstraction layer above the USB communication protocol to send different type of structured data in a very generic and flexible way. **Theoretical answer:**you activate your arduino through USB as a Human Interface Device (HID). Very Short answer: it should not matter to your HID driver and it's going to be a challenge to modify because that's the specification.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |