Author Topic: Scary failure with USB supply  (Read 1582 times)

0 Members and 1 Guest are viewing this topic.

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Scary failure with USB supply
« on: September 02, 2021, 07:15:19 pm »
I just saw a rather scary case of failure when powering a circuit from the USB:

My DIY voltmeter use an SN6505A based DCDC converter (Push-pull transformer driver) for power with a current consumption of some 250 mA at 5 V. So this should be normally be OK to power from USB. I used a USB to UART bridge unit, which has convenient access to the 5 V, and the 5 V wired directly through.  I have it for the data transfer anyway, but this is towards the isolated side, so should not interfere.
I was worried a bit if current spikes could be a bit high and maybe the current on startup or voltage drop under load, so I measured the voltage coming from the USB. No load the voltage was 5.08 V which seem fine.
 
I was however not expecting the way this test failed: the USB supply voltage went up under load: first 5.2 V and later up to 6.7 V at the DC/DC converter input / USB voltage.
This is scary and did cause the UART-USB bridge to get hot enough to smell.  After cool down it still works, so no fatal damage. The DCDC converter has a 6.8 V zener at the input - this may have prevented an even higher voltage. 
 
It this a common problem, or just an exception with a not so well behaved load (some ripple current), or maybe a bad designed mainboard ?
For this is a bit scarry for me, as other USB devices may see the higher voltage too.
 

Offline 2N3055

  • Super Contributor
  • ***
  • Posts: 7278
  • Country: hr
Re: Scary failure with USB supply
« Reply #1 on: September 02, 2021, 09:34:52 pm »
You didn't say what was the USB source..
 

Offline TheMG

  • Frequent Contributor
  • **
  • Posts: 867
  • Country: ca
Re: Scary failure with USB supply
« Reply #2 on: September 02, 2021, 09:54:03 pm »
There's a LOT of variability in the quality and design of USB chargers, especially inexpensive ones from dubious manufacturers.

Some of them can be downright dangerous, not only creating a risk of equipment damage but also can be an electric shock or even fire risk.

What is the brand of USB charger you're using and where did you buy it from?

It likely has a very rudimentary circuit with poor voltage regulation, as it heats up under load the voltage creeps up.
 

Offline mikerj

  • Super Contributor
  • ***
  • Posts: 3338
  • Country: gb
Re: Scary failure with USB supply
« Reply #3 on: September 02, 2021, 10:08:39 pm »
There's a LOT of variability in the quality and design of USB chargers, especially inexpensive ones from dubious manufacturers.

I'd interpreted it as being plugged into a PC/Laptop USB port rather than a USB charger.  It's a USB/serial converter and he mentioned "mainboard".

If it is a PC I would certainly not expect the 5v to rise unless you are inadvertently trying to pump current into the USB port.
 

Online magic

  • Super Contributor
  • ***
  • Posts: 7244
  • Country: pl
Re: Scary failure with USB supply
« Reply #4 on: September 02, 2021, 10:21:49 pm »
More hardware details needed, but :wtf:

Does that computer still work? No fried hard disks and other stuff?
Such things are certainly not supposed to happen. On desktops with ATX PSUs there is simply one 5V rail for everything. I'm not familiar with laptop internals, but unlikely to be much different.

It shouldn't be very sensitive to load, there is a ton of capacitors in there.

If it was a dry test on some USB charger then sure, quality varies a lot and some also try to compensate for cable loss by increasing output voltage proportionally to load current.
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8417
Re: Scary failure with USB supply
« Reply #5 on: September 02, 2021, 11:39:23 pm »
Was it some form of fancy USB-C port? USB-C PD can supply up to 20V, and it's normally negotiated through some insanely complex protocol, but that still scares me based on the fact that it's a variable output voltage that can surely go up if something doesn't work right.

It could also be an attempt at compensating for cable voltage drop that's overcompensating.
 

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Re: Scary failure with USB supply
« Reply #6 on: September 03, 2021, 12:51:12 pm »
The USB power was from a desktop computer (Fujitsu i5..., not very new), just a normal USB2  (maybe USB3, but not on the plug used). The UART unit was kind of only to have access to the pins and as far as I can tell has only 1 or 2 MLCCs at the 5 V and a 0 Ohms resistor in series - so I doubt it did contribute, just suffered.
The local decoupling at the DCDC is a bit on the short side with 2x1 µF MLCC and 10 µF electrolytic - still I had not expected it to be a USB killer.

I have not measured to voltage with the scope, just an old, likely ICL7106 based DMM.

I have the feeling the ripple current from the DCDC converter did somehow interfere with the 5 V regulator on the mainbord side.
 

Online magic

  • Super Contributor
  • ***
  • Posts: 7244
  • Country: pl
Re: Scary failure with USB supply
« Reply #7 on: September 03, 2021, 12:58:24 pm »
There is normally nothing on the mainboard, just a polyfuse connected to 5V from the PSU. (I think MOSFETs to choose between the normal and standby rail are a possibility too, but it's been awhile since I looked at computer motherboards).

If you had 6V on the output, you probably had 6V everywhere. Consider yourself lucky.

edit
How much confidence do you have in:
- the PC PSU?
- the DMM and its battery?
« Last Edit: September 03, 2021, 01:05:05 pm by magic »
 

Offline ConKbot

  • Super Contributor
  • ***
  • Posts: 1399
Re: Scary failure with USB supply
« Reply #8 on: September 03, 2021, 01:04:58 pm »
How did you measure this voltage rise? Scope? DMM? Analog meter? I'd suspect ringing between the cable and the input capacitance played some role here, but if you scoped it and it was indeed DC, and not spikes and ringing, that is indeed quite weird.
 

Online tszaboo

  • Super Contributor
  • ***
  • Posts: 7973
  • Country: nl
  • Current job: ATEX product design
Re: Scary failure with USB supply
« Reply #9 on: September 03, 2021, 01:17:57 pm »
I wanted to make a small board, basically an "USB safety-fyer"
And place an electronic current limiter, fuse, for the power, and a re-driver for the USB data lines.
I wonder if there would be a need for this...
 

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Re: Scary failure with USB supply
« Reply #10 on: September 03, 2021, 01:42:53 pm »
I have quite some confidence in the DMM: it shows a low battery relatively early and did work well the last 30 years or so. The same meter shows normal 5.08 V at the USB supply when nothing bad connected. I did not consider the DCDC converter to produce very much EMI - at least the voltmeter part it powers works fine, with little interference (maybe a little noise in the 7 th digit).  So I don't think there was enough interference for the DMM to read wrong. The input capacitance of 12 µF is a bit low for the DCDC converter, and slightly above the 10 µF that are supposed to be at the USB max. I still don't think it should be so sensitive.

The PC is more like an office computer (lower profile desktop with a more custom power supply). So it is not so easy to exchange, but I also don't expect it to be build super cheap.

It was not just the DMM reading high, but also the chip on the USB-UART bridge  (just used for power through) was getting hot (could smell it and it still felt hot after unplugging it).

Yes I consider myself lucky that nothing got really damaged. I only had the higher voltage for maybe 5 seconds or so.
Anyway I have no intention to repeat.  :scared: :phew: So no more USB power to DIY circuits from this computer.

Just a fuse and maybe a FET to turn off the power is also what I expect on the main board.
It seems the USB uses kind of standby power, as some devices still get power when in standby mode.
 

Online magic

  • Super Contributor
  • ***
  • Posts: 7244
  • Country: pl
Re: Scary failure with USB supply
« Reply #11 on: September 03, 2021, 02:13:32 pm »
It seems the USB uses kind of standby power, as some devices still get power when in standby mode.
I think they switch to the main 5V rail when the PSU is on.
But those branded machines can be weird, some of them use 12V only PSUs with on-board regulators for everything else.
Anyway, that's some bizarre stuff.

I presume that simply loading USB with 250mA doesn't produce the same effect?
 

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Re: Scary failure with USB supply
« Reply #12 on: September 03, 2021, 08:28:04 pm »
I have not tried, loading the USB with a resistor, but other loads (charge digital camera, WLAN and external USB harddisc) did work.
 

Offline 2N3055

  • Super Contributor
  • ***
  • Posts: 7278
  • Country: hr
Re: Scary failure with USB supply
« Reply #13 on: September 03, 2021, 09:36:25 pm »
The USB power was from a desktop computer (Fujitsu i5..., not very new), just a normal USB2  (maybe USB3, but not on the plug used). The UART unit was kind of only to have access to the pins and as far as I can tell has only 1 or 2 MLCCs at the 5 V and a 0 Ohms resistor in series - so I doubt it did contribute, just suffered.
The local decoupling at the DCDC is a bit on the short side with 2x1 µF MLCC and 10 µF electrolytic - still I had not expected it to be a USB killer.

I have not measured to voltage with the scope, just an old, likely ICL7106 based DMM.

I have the feeling the ripple current from the DCDC converter did somehow interfere with the 5 V regulator on the mainbord side.

Thank you for answer.
Yep, PC is getting USB power from 5V power bus directly, and cannot produce 6V.. It has to be  some back driving by device or inductive pulse or something.
That is kinda small decoupling on input of DC/DC converter. You could try adding 100uF to it and test.
Measurement artifact not very likely with a DMM.
I guess a short USB extender cable will have to give it's life to science... Expose wires and measure with a scope.  Or if you feel like it make a little measurement pickup through board to get test points exposed.
 

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Re: Scary failure with USB supply
« Reply #14 on: September 03, 2021, 10:20:44 pm »
I think I will look at the PC internals tomorrow. It was one of the front side connectors, just in case it matters, so not directly the plugs on the moterbord.

The circuit definitely had not way to backfeed extra power, as the USB was the only power source.
It would be more like excessibe ripple, though normally this should not happen, as the load should be relatively symmetric on both half cycles.
The regulator may just behave poor at some 160 kHz. This about the frequency where voltage regulators can tend to oscillate, so a boarderline regulator with a nasty load (possibly some negative impedance in this frequency range) may have come together.

I probably won't do experiments with this USB part, so sorry - no scope traces.

The filter capacitance is a bit tricky. The transformer driver wants a bit more capacitance.The USB specs want 10 µF max, if there is no extra current limit.
The ripple, if powered from a pretty slow lab supply with not very much capacitance at the output is visible, but not too large. I check the amplitude tomorrow.
 
The following users thanked this post: 2N3055

Online magic

  • Super Contributor
  • ***
  • Posts: 7244
  • Country: pl
Re: Scary failure with USB supply
« Reply #15 on: September 04, 2021, 05:46:29 am »
I have exceeded the 10µF spec before I knew it exists; I think 100µF was my record ;)
Maybe some choke and/or small resistance on the input could smooth out the inrush transient and also isolate your switching junk from the PC.

As much as I would like to know what happened, I don't think it is objectively a good idea to attempt reproducing this condition when it isn't know what else sits on that 5V rail in the PC.
 
The following users thanked this post: Kleinstein

Online KleinsteinTopic starter

  • Super Contributor
  • ***
  • Posts: 14854
  • Country: de
Re: Scary failure with USB supply
« Reply #16 on: September 04, 2021, 08:07:27 am »
As far as I see it the 10 µF upper limit USB wants is there to limit inruch currents. So the supply does not collaps if a new USB divice is plugged in. With extra measures to limit the inruch current more is allowed.

When I build the circuit I also did not know about this limit, and I did not even planed for USB as a supply. It was just coincidence that my 12 µF (nominally) are only slightly above, but this should not be the reason.

I checked the ripple when powered from a lab supply: 10 mV_pp (about triangle waveform) at some 330 kHz - so as expected twices the DCDC working frequencies. I don't think the lab supply (old DIY one) has a very low impedance in this frequency range.
Some choke / filtering would probably help and be a good idea. I have a CM choke planed, but not yet populated :palm:. The stray inductance of the choke would have helped at least a little.

The other point may be some optimization at the DCDC converter, like something to reduce peak currents a little. It currently looks like it draws quite some peak currents - maybe my DIY transformer is too low in stray inductance.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf