I have an Arduino Mega 2560 R3 from Elegoo and a USB Host Shield (https://www.amazon.com/gp/product/B08PNVKKBH).
I want to connect a Logitech F710 wireless gamepad that runs over 2.4GHz to an included USB receiver (https://www.amazon.com/gp/product/B0041RR0TW).
I was going to use the USB Host Shield 2.0 library, but on the github page (https://github.com/felis/USB_Host_Shield_2.0), it says "Note that a Wireless controller can NOT be used via USB!" Before I go into my troubleshooting steps, it sounds like my setup isn't supported. Am I reading that correctly? If so, has anyone gotten this to work successfully or do I need to go buy a different controller?
I've verified that the USB shield is getting power and initializing correctly. When I run this code:
#include <Usb.h>
#include <usbhub.h>
#include <hidboot.h>
// USB Host Shield object
USB Usb;
// Create an HIDBoot object without specifying a specific protocol
HIDBoot<USB_HID_PROTOCOL_NONE> Hid(&Usb); // Use USB_HID_PROTOCOL_NONE
void setup() {
Serial.begin(115200); // Start serial communication
// Initialize USB Host Shield
if (Usb.Init() == -1) {
Serial.println("USB Host Shield initialization failed.");
while (1); // Halt if initialization fails
}
Serial.println("USB Host Shield initialized.");
}
void loop() {
Usb.Task(); // Poll the USB Host Shield
// Add a debug message to show it's running
Serial.println("Polling for HID device...");
delay(1000); // Delay for readability
}
it outputs
USB Host Shield initialized.
Polling for HID device...
...
Some other things I've tried:
- I have tried all of the examples in the USB Host Shield Library and none of them register button presses.
- The controller has a D and X mode. I've tried both.
- I've verified that the controller works on my mac in D mode.
- I've verified that a device connected to the USB hub has power. The Arduino is plugged into my computer via USB and a 12v 1a power adaptor.
Naturally, I tried all this before I read that it may not be supported at all. I'm new to posting, so I hope this is enough information and follows all the rules/etiquette. Any advice would be much appreciated.