One Arduino Leonardo with 3 different selectable USB Configuration at Startup!

hi everybody.
I want to make a multi-purpose USB device with Atmega32u4 core. with 3 different USB Configuration & 3 different USB VID/PID:
1- HID USB Joystick1 with VID1/PID1
2- HID USB Joystick2 with VID2/PID2
3- MIDI Controller with VID3/PID3
I want to use 2 digital pin of atmega32u4 to select one of the above.
if 00 -> set configuration 1 in boot time
if 01 -> set configuration 2 in boot time
if 10 -> set configuration 3 in boot time

It is easy to do just one of these settings. And there are many examples about this. Like making a joystick or making a MIDI controller and ... But choosing one of these three modes when connecting the USB cable to the computer is very difficult and I don't know how to do it.
If anyone has a project done in Arduino or Atmel Studio, please introduce it to me.
And if anyone can help or guide me, I would be grateful.

try searching for a USB 3:1 multiplexor, e.g. Texas USB redrivers & multiplexers
I have used the 2:1 ISL54200 Active USB 2.0 High/Full-Speed Multiplexer - never tried a 3:1

1 Like

Hi. Thanks for your reply.
I think I didn't express my point correctly.
I am planning to introduce an Arduino Pro Micro device to the computer as both USB HID and USB MIDI, in a way that this introduction can be selected during connection, and I don't want to use USB Composite.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.