Skip to main content
VDodi.1
Associate III
January 23, 2023
Solved

Is it actually Possible to define multiple distinct HID joysticks on one interface? I have Nucleo F439ZI Board

  • January 23, 2023
  • 2 replies
  • 2208 views

..

This topic has been closed for replies.
Best answer by Jaroslav JANOS

Hi,

first of all, having 2 configurations won't solve your problem. As mentioned in the training, configurations are used for different "power modes" of the USB device. What you need is to have 1 device descriptor, 1 configuration descriptor and 2 interface descriptors (assuming you are going the "composite device way").

If you are using ST Middleware, you need to change interface descriptors in usbd_hid.c file, and also other functions, e. g. for reporting and enumeration of the device.

BR,

Jaroslav

2 replies

Jaroslav JANOS
ST Employee
January 26, 2023

Hi @VDodi.1​ ,

yes, this is possible either with multiple HID Top-level collections (if you mean under the term "interface" the logical USB interface) or with a composite device (multiple USB interfaces, but still one device = one HW interface).

BR,

Jaroslav

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
VDodi.1
VDodi.1Author
Associate III
January 27, 2023

thanks, actually i have configure my nucleo board as device and pc as host and created joystick controller interface. now i have to do multiple joystick controller with one device.

can you help how to send my data from device to pc as host ??

Piranha
Principal III
January 27, 2023

Yes, and here are several different examples:

https://github.com/hathach/tinyusb/tree/master/examples/device

VDodi.1
VDodi.1Author
Associate III
January 27, 2023

thank you