I’d like to make an HiD translator which will present a USB Host to a PS3 controller, convert joystick to mouse movement and buttons to keyboard keys and then present USB HiD keyboard and mouse devices to a PC.
I’ve coded up an Arduino 32u4 to take in two RC receiver signals(RC PWM) and create a joystick HiD device for use on an rPi robot but I’ve not yet found a small device which can be both a USB Host and also present USB HiD devices.
Looking for device ideas. Currently considering Arduino, Teensy and rPiZ if solutions exist.
A quick search shows that the easiest way is to use a USB host shield for an Arduino. Here’s one of many articles that talks about how to do that. Search for USB host shield and decide which one you want to try.
This one is a wealth of information.
The Host board is a Microchip with USB host capabilities but that board is not available. Their firmware and the chip is available so an option would be to make a board and mount it to something like a Leonardo based 32u4 board for the USB HiD side. Ok, that’s a possible solution. Thanks.
I will see what the Arduino Host boards use since it’s unlikely they use a Microchip part so maybe there’s another host chip + HiD capable board option. An rPiZ seems overkill but I found that the Teensy will do USB Host so just need to see if it can also do USB HiD at the same time.
I had been staying away from the Arduino Host Shields figuring they were for the full size Arduino but there are some for smaller which should work with something like the 32u4 based Pro Micro which has USB HiD support. Cool.
Also found the other chip used and supported by Arduino for host mode is the Max3421e chip.
A single board option would be great but keeping it small like the Pro Micro footprint is A-OK too.
Thanks, me too and best of all some smaller boards too. Like this one which might also be found on amazon for $12 but I could not see the chip ID - Mini USB Host Shield 2.0 ADK MAX3421 SLR development MAX3421EEHJ module|Integrated Circuits| - AliExpress
I’m glad you were able to find something that might work. I’m always willing to pay a little extra from Amazon only because I know it will come quickly and I can return it if it’s not what I really want.
I have step one working, that is wiring a USB micro Host board to a TeensyLC and getting the PS3 working over Bluetooth dongle wireless.
Teensy LC: Teensy® LC
ideapro USB Bluetooth Adapter, 4.0 Dongle: https://www.amazon.com/dp/B00OH09OXS
HiLetgo 2.0 ADK Mini USB Host Shield : https://www.amazon.com/dp/B01EWW9R1E
Nano/Pro_Micro/TeensyLC Signal USB Mini Host shield
D10 / 10 / 10 SS 5
D11 / 16 / 11 MOSI 6
D12 / 14 / 12 MISO 7
D13 / 15 / 13 SCK 8
D2 / 2 / 2 INT 2
5V / VCC / 5V V_BUS 1
3.3V/ ?? / 3V VCC 9
GND / GND / GND GND 3
RST / RST / 3V MAX_RST 4
Documenting for others who may look for this.
Have you considered using the RP2040? It can be a USB HOST or peripheral, and you ca n code it with Arduino IDE or Micro Python/Circuit Python
I have not tried the RP2040 yet and have been using a Teensy for this project.
I do want to dabble in Micro and Circuit Python but have plans for porting a Kinetic Clock project from an ESP8266 Arduino to Micro Python on the ESP8266 or ESP32. Thanks for the thought of using the RP2040, it’s showing up in lots of projects these days.