Skip to content

Implement HID support library #838

Closed

Description

@williampMSFT

We need a HID support library to enable:

  • Macro to declare HID reports that yield struct definitions and TryFrom/Into implementations
  • Functionality to logically concatenate a collection of N descriptors (will require parsing and renumbering)

Activity

  1. self-assigned this
    on May 8, 2026
  2. makubacki commented on Jun 19, 2026

    @makubacki

    Patina has some HID support - OpenDevicePartnership/patina-components#8

    It's ported from code in https://github.com/microsoft/mu_rust_hid. In the spirit of ODP code sharing, do you or @joschock think there is an opportunity for some layer of common HID support code?

  3. joschock commented on Jun 19, 2026

    @joschock

    Patina has some HID support - OpenDevicePartnership/patina-components#8

    It's ported from code in https://github.com/microsoft/mu_rust_hid. In the spirit of ODP code sharing, do you or @joschock think there is an opportunity for some layer of common HID support code?

    mu_rust_hid is a general-purpose rust HID Report Descriptor Parser - it's not directly tied to UEFI but it is used by the UEFI hid components (both the older free-standing rust implementation in Mu as well as the patina component used above).

    For the use case above, you could extend it with a HID Report Descriptor Generator. The parser that exists today can take a HID Report Descriptor and produce a rust-code representation of that. It'd be a fair amount of work, but you could write something that would take the rust-code representation of a descriptor and convert it back to a report descriptor format. Once you have both the parser and the generator, then a bit of business logic would allow you to parse, manipulate, and then re-generate.

  4. williampMSFT commented on Jun 19, 2026

    @williampMSFT
    CollaboratorAuthor

    awesome, thanks for the pointers! currently working on getting a single device working, but once I have that working this is next on my list, so I'll definitely take a look at these and see if there are opportunities to leverage/enhance these

  5. williampMSFT commented on Jul 18, 2026

    @williampMSFT
    CollaboratorAuthor

    Looked into the patina HID stuff, but it looks like that environment has access to a heap that it leverages for some of the HID stuff, and we don't have one on the EC, so we're going to need something a bit different here.

    I have the pieces I need for the device aggregator implemented in https://github.com/williampMSFT/embedded-services/tree/user/williamp/hid-aggregate-new; however, it depends on https://github.com/williampMSFT/embedded-services/tree/user/williamp/hid-i2c-rework, which is blocked on OpenDevicePartnership/embassy-imxrt#565, which is blocked on a rework of the I2C HAL trait that's necessary because the current one is not correctly implementable on MCXA hardware. Once my chain of dependencies go in, rebase on top of that and get this in.

  6. added a commit that references this issue on Aug 4, 2026
    9cabed8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions