Skip to main content
Visitor II
May 27, 2023
Question

Creating multiple HID devices on STM32 controller

  • May 27, 2023
  • 1 reply
  • 1649 views

I recently got into STM32.

My goal is to use my 1 controller to simulate multiple keyboard on my Windows computer.

Currently, I managed to get a setup that works for 1 keyboard (1 HID device) using the Custom HID device settings on the CubeIDE.

I'm trying to progress into having multiple keyboards (multiple HID devices) and I'm having a really hard time figuring out what to do.

From what Iv'e read on the forums, I understand that there are 2 option for what I'm trying to do:

Composite USB

Having multiple HID interfaces on the same USB output.

I'm mostly trying to do the second option, but I think either one would work for me.

I'm really struggling with instruction on what to do, I found a few forum posts, but I couldn't really understand what to actually do, I don't really understand what I actually need to change in my code in order to have multiple HID interfaces in it.

If anyone could give me some tips or resources it would be highly appreciated, thanks

    This topic has been closed for replies.

    1 reply

    Technical Moderator
    May 31, 2023

    Hello @pgold.1​ and welcome to the Community :) ,

    To implement the USB device composite, I recommend you to start from an available example. 

    For that I recommend you to take a look to this HID composite application (Mouse + Keyboard) application based on USBX middleware running on STM32H747.

    So, try to get inspired from the instructions in the readme file.

    When your question is answered, please close this topic by choosing Select as Best. This will help other users find that answer faster.

      

    Kaouthar