Finally got an ESP32 with the Arduino IDE working with the USB Mini 2.0 boards that I have. They actually say Du1noFun USB m1m1 v2.0. dated Aug. 16, 2014
Counted pins on DuinoFun CCW from the bottom left corner like an IC with USB connector to the left. Skipped the pads across the right end. So 12 pins on each long side. See picture here: https://www.arduino.cn/thread-81435-1-1.html
Found out from this page that my DuinoFuns had the pins mismarked. Followed the drawing here which is correct. Credit to kn1cht and philipn7 for pointing him out at: ESP32 with usb host shield · Issue #1271 · espressif/arduino-esp32 · GitHub
Use ESP32 Pins to DuinoFun Pins Signal and notes
D5 P1 SS
D23 P2 MOSI
D19 P3 MISO
D18 P4 SCLK
D17 (TX2) P23 INT
3V3 P9 3.3V
VIN (5V really 4.56) P24 VBUS
3V3 P15 RST (is connected thru 3.3K to 3V3 and directly to EN)
GND P11 GND (possilby other GND on P16)
In order for this to work, the patch was made that removes the trace between VBUS and the 3V3 power bus near the 2.2K resistor. Anyway, if wired this way, make sure P24 does not have continuity to P9. You can see an example of this patch here: https://www.hackster.io/139994/plug-any-usb-device-on-an-esp8266-e0ca8a
Next, per blog entry by hyshiah on this page: https://github.com/espressif/arduino-esp32/issues/1271 made changes to usbhost.cpp and avrpins.h. I'm not sure if this is necessary but the whole thing is really complex, how it tries to incorporate all kinds of possible boards and initialize the SPI with the right pins. This patch adds a macro
in avrpins.h to return the pin number associated with a pin name like SPI_CLK (you see them all over the place along with some function like SPI_CLK::clear(). This patch adds SPI_XXX::pinNum()) Finally, another "if" is added to usbhost.h to use the new macros to call SPI.begin() with the pins as parameters. Guess it works because it now
communicates with the ESP32.
So to use the USB Mini on the other SPI channel on the ESP32 all you need to do is change the pin assingments in the avrpins.h file. I assigned 12 to P19, 13 to P23, 14 to P18 and 15 to P5. That corresponds to MISO, MOSI, SCLK and SS. Changed the wiring to these pins and it worked. These are all dedicated pins for the SPI bus.
After getting the USBDesc example to work with this arrangement, tried the FTDI loopback example and it worked. I found all of these examples to have strange output features. Not just Serial.println() or something. Made changes to something I recognized. So finally got around to the CP210x loopback example in Henrik Larsen's Github fork of the standard USB_Host_Shield_2.0 library: Https://github.com/henla464/USB_Host_Shield_Library_2.0
All I really did was add the CP210x.cpp and CP210x.h files from Henrik's forked library and tried his CP210x loopback example. It's really just like the FTDI loopback example but with a couple different includes, etc. Worked great. I just plugged another ESP32 into the DuinoFun module with a USB cable so the first ESP32 was talking to the second one's CP2102.
Hope this helps someone who has been having trouble making this work and maybe I'll get the hang of this corkscrew editor. Really kind of a crap shoot what it looks like when you are done.
Edit: So I tidied this explanation up some, drew a wiring diagram, made an example .ino program, and zipped up my version of the library that works. You can see all this by going to my website to read or download any of it here. Hope that helps.