I'm writing this post because I had troubles that nearly had me losing my mind, but by piecing together various bits of info was able to figure it out, so hopefully this helps someone else.
I bought one of these Gravitech USB Host Add-ons (USBHOST add-on for Arduino Nano) for the Arduino Nano, thinking that based on its dedicated design it would be natively compatible. I dropped the Nano onto the headers and fully of expectations uploaded the example sketch board_qc to check that it was functioning correctly, only to have it fail the test:
Circuits At Home 2011
USB Host Shield Quality Control Routine
Reading REVISION register... Die revision invalid. Value returned: 00
Unrecoverable error - test halted!!
0x55 pattern is transmitted via SPI
Press RESET to restart test
I searched around for answers and found this blog post: USB Host Shield for Arduino Nano, which contained a description of the problem:
"the pins for SCK, MOSI, and MISO were correct. But the USBHOST-4NANO is expecting SS on pin D8, and the Nano is using pin D10."
but an incomplete explanation of how they got it working,
As to how to fix this, it turns out that editing the UsbCore.h file solves the problem.
So in this library: GitHub - felis/USB_Host_Shield_2.0: Revision 2.0 of USB Host Library for Arduino., edit UsbCore.h on line 56. Change:
typedef MAX3421e<P10, P9> MAX3421E;
to
typedef MAX3421e<P8, P9> MAX3421E;
and then re-upload your sketch to the board. For me this worked. I would guess that this would prevent the regular USB Host Shield for Arduino Uno, etc., from working, so this parameter may need to be changed back and forth depending on what board you're working with.