Teensy with mini USB host shield (chineese)

Status
Not open for further replies.
Bought another one, since they're pretty cheap, and it would help me diagnose.

This one doesn't seem to exhibit the problem when pulling MAX_RST high, but still fails the same way (SPI short test passes, SPI long test fails). The troubleshooting guide seems to indicate this is due to a bad crystal oscillator, but it seems unlikely I got two bad units with the exact same defect.
 
Hi,

How is going on? I have got the mini usb host from the web (in fact I'm a Chinese arduino hobbyist). And I have made a board which can use the USB host with Arduino Pro Micro(32u4, Leonrado).

And for the next step, I want to use this mini USB host on teensy 3.2. But it doesn't work.......
 
Good day. Sorry for dredging up an old thread here, but it has been an insightful one, to say the least.

I am writing to question if it is a reasonable expectation that these shields ship with firmware installed, or is it typically necessary to compile and flash the USB Host code onto the shield too, in addition to user code that includes the C@H libs to interact with the shield on the host Arduino?

Reason I am asking that is I have bought a couple of shields (the larger one from SainSmart (UHS v2.0) and the exact same board that the OP posted about herein (the duinofun.com UHS mini v2.0 with the same erroneous silkscreen on the underside)) to interface with non-arduino host micros/SBCs, for a custom control solution via a HID device. If I don't need to program the shield, then I would be pretty geeked about that, and just start to port the HID code for the host.

Thanks to the participants of this thread for helping the OP, for providing the correction to the faulty mask, as well as the balance of the device pinout. It is much appreciated and will likely save me some hours reverse engineering the PCB. Kudos.

~MHz
 
My understanding is the shield has only a MAX3421E chip, which can't be programmed. It has no flash or other programmable non-volatile memory.

All the programming is done on Teensy or whatever microcontroller board you connect.
 
I have make a simple board which can connect Teensy 3.2 and USB Host Mini together. It works well with the USB host library. I'd like to share it later.
 
Hello All, I have successful enable Usb Host Mini on Teensy 3.2. You can find the detail in

https://www.arduino.cn/thread-81435-1-1.html

This doesn't actually work. It get you as far as the diags of the internal functions of the chip and I have never had trouble with that. It runs all of the stages of the tests but it stops short of actually connecting to anything plugged into the USB which is where most of the trouble is. I have 7 of these boards. 1 of them fails the diagnostics from the beginning and the other 6 do all the things that Zoologist describe but none of them actually connect to a USB device. They just wait. I have tried on Teensy 3.2, T3.6, T4.0 T4.1, Arduino pro mini 3.3v, STM32 blue pills, oh, and the Teensy LC. Seems some are lucky with these mini USB boards and others just aren't. They are another item I wish would be removed from the market. A bit too expensive for a hit and miss product.
 
I have also enabled this board(USB Host Mini) on ESP32

https://www.arduino.cn/forum.php?mod=viewthread&tid=94444&extra=

And here is the project for connection HP-9800 with USBHostMini and DFRobot ESP32 board.

https://mc.dfrobot.com.cn/thread-305452-1-1.html

Can you check the power and the reset pin of your USB Host Mini board.

I have gone through everything I have been able to find on the web on these things (seven host boards in all). I have done the bypass of the power. I have clamped the reset with and without pull up resistors, 1k and 10k. I have set up with 470uf capacitors for surge buffering as per Pauls suggestion. I have tried them on un-bridged on 3.3v and bridged to 5v on three different keyboards, about ten USB memory sticks, three music keyboards, four other USB midi based music devices, mice and various other USB devices. I have tried them on Teensy LCs T3.2, T3.6, T4.0 and T4.1s. I bought and tried three 3.3v 8Mhz Arduino Pro Minis (the native device apparently) along with STM32 blue pill clones.

I have tried every library version I could find even when they seemed the same as other library versions just in case. I have tried nine different versions of the Arduino IDE spanning from around v1.1 up to v1.8.13. Some of these I ran on four different computers just in case even though it didn't make sense. I put the boards under my digital microscope and checked all of the traces and connections with continuity testing looking for shorts and unwanted breaks. I traced all of the connections to the chip with continuity testing and tested every connection on the board for shorts against it's neighbors and many other traces. With the board_qc.ino sketch (I have tried about 4 of the other demo sketches as well) all but one of the host boards pass all of the tests (even the GPIO loop back tests wired up a few times) right up to the handshake with the USB device where it fails every time.

Interestingly Midi controllers power up when connected to them but none of the computer keyboards or other USB flash drives do. I even had a Canon image scanner take the power to try to initialize but of course nothing else. The sketch didn't see it.

I started with two boards from one seller and one worked up to that point and the other didn't so I went to a completely different source and bought another five figuring that would improve my odds and I could certainly use more than one anyway.

Oh and for the 5v bypassed supply I have used my bench top supply set to 5v monitored with an oscilloscope to check for a clean supply. also 2 lithiums in series feeding a 5v regulator. I also have tried turning off and on the Teensy optimizations in the libraries. I have spent way more time on these things than I really should have. I really need to get one going and it is holding me up from other things. Today I took delivery of a full sized version of the shield. I've decided that if that doesn't work by Sunday they all have a date with a hammer. I have to force myself from being tempted to try or buy anything else. Unfortunately there are very few if alternatives to these boards for hosting. All this so that I wouldn't waste a now expensive Teensy 4.0 on such a mundane application. It has cost me a lot more than a T4.0. Realize also that every time I get a new thing to try it gets tried through most if not all of these combinations all over again.

At the moment my theory is that even if you are giving the device plugged into it 5volts you are still communicating with signals based on 3.3v on the host and who knows what from the external device. Sometimes it may work and sometimes it may not. Some hosts may go to owners that have just the right combinations of devices to get the communications needs met. The rest of us are just screwed and wasting money. It could explain why the full sized shields have a higher success rate.
 
Oh, I konw your feeling. A few years I was blocked by this shield for weeks. And it made me so angry.

I think you can get a full size shield, it should always work well. And after that, you can confirm which version of library is working.

From my experience, debugging this board can be sperated into two parts:

1.Confirm if the MAX3421E works well. Don't connect a USB device to the USB Host baord. Then uou can check the commnuication on the SPI bus. If there is no date on MISO (MAX3421E doesn't reply your command), please check the power supply of MAX3421E. This IC works on 3.3V. Please confirm the Pin on the IC. After that, please check the RESET Pin of IC. It should be always HIGH. At last, I think the voltage of SPI should be 3.3V.

2.Confirm if the USB device works well. This MAX3421E works with 3.3V, but USB device must have a 5V VCC.

You have an oscilloscope,it would be much easier for you to check them.
 
Here a three links that helped me when I was testing the mini.


From what I remember the Chinese knockoffs seemed to have problems with crystals and it was hit or miss if they worked. I ordered mine directly from CircuitsHome and it worked out of the box. The 2 knockoffs I had gotten I never could get working. I do know that the mini from sparkfun does work.
 
Oh, I konw your feeling. A few years I was blocked by this shield for weeks. And it made me so angry.

I think you can get a full size shield, it should always work well. And after that, you can confirm which version of library is working.

From my experience, debugging this board can be sperated into two parts:

1.Confirm if the MAX3421E works well. Don't connect a USB device to the USB Host baord. Then uou can check the commnuication on the SPI bus. If there is no date on MISO (MAX3421E doesn't reply your command), please check the power supply of MAX3421E. This IC works on 3.3V. Please confirm the Pin on the IC. After that, please check the RESET Pin of IC. It should be always HIGH. At last, I think the voltage of SPI should be 3.3V.

2.Confirm if the USB device works well. This MAX3421E works with 3.3V, but USB device must have a 5V VCC.

You have an oscilloscope,it would be much easier for you to check them.

Not sure that you are responding to me on this one but just in case you are, I've done all of that many times over and tried it on just about every USB device I have. If it will only work on some random USB device I haven't seen yet then it really isn't of any use for anything. Infuriatingly a new update for the libraries seems to have turned up since I last attacked this problem and I have this horrible feeling that there is one unit somewhere in my stores that escaped the rubbish bin.

I did notice on the last attempt that the circuit design on these cheap clones have had modifications to the USB device side that seem to serve no improving purpose other than to save the cost of a SMD resistor or two (compared to the original version of 10 years ago (or the full sized UNO shield, can't remember which)). They even came with different resistor and capacitor values from unit to unit in the same batch of 5. Looking at the circuit traces in that area (between the chip and the USB host port) seemed to make no sense and looked like a B grade clone of the original had been created in a hurry and not checked beyond the 2nd last test (not beyond the MAX3421E tests) before they went into production. All of the tests work well to this point on all but one board that was just DOA. It is the interface between this and the final USB device where everything falls down and I find it interesting that this is the only place on the board where the circuit isn't the same as the original, simpler, more logical layout that was designed to implement the 5 volt bypass where needed. The clone (the only one we can get now) with the 5 through holes in a line is the one that you have to hack the traces to make the mod.

I can only conclude that these things were knocked out in a cynical effort to cash in on the far better original design with no interest from the manufacturers to make them actually work and strangely they just keep on making them year after year and the only users that have any success with them only describe them up to the second last test before the handshake with the USB device and, I hate to say it, seem like they work for the company. If you are charging $20 and up on a piece of junk for year after year and us suckers keep buying them I suppose it might seem worth continuing to sell them until the dodgy production run sold out. It's like the STM32 blue pill clone that has been selling for years with the wrong SMD resistor on the USB port that you have to change to get it working. Trouble is these USB hosts just don't work at all ($25 - $50). The Blue Pill at $1.60 does after you swap out the single resistor. (Just a shame that I far prefer Teensys over all else I've tried. Paul knows how to handle a device rollout and is obviously proud of his devices and well, they just work.) Had the original USB hosts still been available they would have been the ones to get. No doubt about that.

The original reason why I kept one of these boards from the bin was so that I could try bypassing all of the changes over the original that the clone has and hand building the original designers USB stage to see if that will do it. (I'm just waiting until I hate myself enough to put myself through this Sisyphean punishment again.)

Who'd a thought that cheap clones could go wrong, eh?
 
Here a three links that helped me when I was testing the mini.


From what I remember the Chinese knockoffs seemed to have problems with crystals and it was hit or miss if they worked. I ordered mine directly from CircuitsHome and it worked out of the box. The 2 knockoffs I had gotten I never could get working. I do know that the mini from sparkfun does work.

Do you mean the full sized (UNO shaped) board? There is no doubt that they work for the most part but the issue is the small USB host boards made for the Arduino Pro Mini profile (more specifically the clones of them that have flooded the market). The original design seems to have been just fine but now you can only get the screwed up clone.
 
This probably won't help much, but here's a page written 10 years ago when I tested Oleg's original hardware (long before any Chinese clones existed) with Teensy 2.0 and Teensy++ 2.0, which were the only 2 Teensy models in 2011.

https://www.pjrc.com/teensy/td_libs_USBHostShield.html

Hey there Paul. How goes it in Portland? Do you now if there is still a source out there for Oleg's original designs? The circuitsathome link seems to be a dim distant memory now unless I'm missing a hidden link somewhere.
 
Do you now if there is still a source out there for Oleg's original designs?

No, sorry, I have absolutely no idea. I haven't used any USB host shield in recent years.

Not long after we released Teensy 3.6, I poured about 1 year into writing the USBHost_t36 library. Rather than take the simple blocking 1-thing-at-a-time approach of the USB Host Shield library, I wrote a completely new library from the ground up for EHCI, using a structure pretty similar to how Linux supports EHCI. It's really a day-and-night difference from UHS, both in terms of hardware and software.

Now that we have 2 Teensy models with really good USB host hardware (including current limited switches and 100 uF capacitors so hot plugging works nicely), and another with data-only access to ECHI-based USB host, I really haven't looked back at any of those old host shields.

Seriously, just get a Teensy 4.1 or Teensy 3.6. Why waste time messing around with such kludgy hardware?
 
Status
Not open for further replies.
Back
Top