Burnt regulator pluggin in USB while ext power was on

Hi! This is something strange that has happened to me twice in the last 2 weeks

I have a large project going on. Basically an Arduino Mega 2560 with:
-RTC I2C clock
-I2c 128x64 screen
-Simple 1xrelay board
-Wiegand RFID reader
-Ethernet shield

This has been working properly for many weeks. It is always connected to ext +12V as my RFID reader needs 12v, and also to V-USB as I'm programming and debuggin on USB all the time. Having both supplies at the same time has seemed to be working fine for several weeks

But...one day I disconnected the USB cable to check the project while OFF the computer, keeping the ext +12V supply, it all worked good, but as soon as I plugged in the USB connector, something burned in the board and smoked heavily. I checked it and it was the board +5v regulator. I thought it was some loose wire that had shortcircuited something

I switched to another Mega2560 board I had at hand, and it all started working fine again, until today when I, once again, unlugged the USB, checked it running only on ext +12V, and as soon as I reconnected USB, it burned again.

It's weird as I haven't found this happening to anyone else on google. Anyone can guess what's happening? I need to note that it works fine while it's connected to both supplies, but when I disconnect USB and reconnect it while +12V is on, it burns....

Thanks in advance!
Eduardo

edugimeno:
This has been working properly for many weeks. It is always connected to ext +12V as my RFID reader needs 12v,

Eduardo

Show i diagram of your connections and supplies, pay attention to grounds.
It is possible something has changed slightly or your basic connections could be wrong.

Sometimes the power up sequence can be important to prevent damage.

EDIT

Is your weigand device optoisolated ?

Thanks, it will take me some time to draw an schematic but in the mean time I can give you some details:

-Relay board, connected to GND/+5V/D5
-Wiegand connected to GND/D2/D3/Vin (D0 to Dig2, D1 to Dig3)
-LCD and RTC 100% both into the I2C bus (ck and data), and GND/+5V

I don't think it is related to signal pins (isolation) as it only happens at soon as you reconnect USB while Vin is connected. Same effect twice.

Im wondering if pulling power for the Wiegand reader from the Vin pin is the issue...It is only "1 diode away" from pure +12V but...

The Mega (~75mA), ethernet shield (~150mA), 1-relay board (~80mA), and LCD backlight (? 20-50mA) alone will generate more than 2watt of heat in the onboard regulator when powered from 12volt. Too much.
Leo..

You are missing the point, I wanted to make sure I noted the key here
This board works great for days (i checked it) when only powered on 12V
This board works great for days (i checked it) when only powered by USB cable
This board works great for days (i checked it) when powered from both (+12V ext and USB cable)
But the regulator burns in 1/100 of a second when I plug the USB cable in while working off the +12V power

It's the transition from "only 12v" to "12v and USB" power what burns it. Right away. Twice so far

edugimeno:
I don't think it is related to signal pins (isolation) as it only happens at soon as you reconnect USB while Vin is connected. Same effect twice.

Having the weigand reader connected and powered could cause volts greater than 0V to an arduino input pin.
This could blow the gate so that when the arduino is powerd up by the USB causes a short , blowing the regulator , possibly ?.

The volts applied to an input pin should not be more than than VCC and if the arduino is not powered at the time it wil be the case.

Boardburner2:
Having the weigand reader connected and powered could cause volts greater than 0V to an arduino input pin.
This could blow the gate so that when the arduino is powerd up by the USB causes a short , blowing the regulator , possibly ?.

The volts applied to an input pin should not be more than than VCC and if the arduino is not powered at the time it wil be the case.

Yes but I never have all the logic off while the reader is ON. When it's on 12v (powered on Vin), everything is powered, the wiegand is direcly powered and the Mega is powered thru the regulator
When its only on USB, the Mega is powered directly from USb and the wiegand is OFF as is requires 12V and there's no "output current" on Vin
Its only when (absolutely WHEN, not a second before, not a second after) I reconnect USB while Vin has 12V

edugimeno:
Its only when (absolutely WHEN, not a second before, not a second after) I reconnect USB while Vin has 12V

There is an fet switch tat controls the change of supply to the arduino.
Perhaps there is a transient happening which is destroying something.

Do not know though.
Not experienced it with genuine UNO except from wiring issues. However have had similar unexplained power problems with Chinese clones.
Unexplained failure of the regulator chip.

Hi,
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Specifically the order and layout of your gnd wires.

Thanks.. Tom.. :slight_smile:

Are you powering the Wiegand board from the Mega's Vin pin? Its not designed for that, you're drawing current through a diode that may be overheating. Look at diode D1-M7 on the upper left end of the schematic. The Vin pin is for supplying power INTO the Mega.

It sounds to me like the ground of your 12V supply is at a different potential to the ground from your computer. That would explain all the symptoms you describe, so look at the ground leakage from your computer's supply.

outsider:
Are you powering the Wiegand board from the Mega's Vin pin? Its not designed for that, you're drawing current through a diode that may be overheating. Look at diode D1-M7 on the upper left end of the schematic. The Vin pin is for supplying power INTO the Mega.
https://www.arduino.cc/en/uploads/Main/arduino-mega2560-schematic.pdf

This is something I thought too, but when I checked the schematic I understood there shouldn't be any issue with pulling power from Vin, it's, like I said, 1 diode away from +12V. Yes the Wiegand would be drawing current from the diode, but it works in the order of dozens of mA
Even though, I don't see how the regulator would burn ONLY when I plug the USB port while +12V is powered
Thanks

Grumpy_Mike:
It sounds to me like the ground of your 12V supply is at a different potential to the ground from your computer. That would explain all the symptoms you describe, so look at the ground leakage from your computer's supply.

This is some interesting comment and, without even 100% understanding it...it sort of makes sense in my head.
How do I check a ground leakage in my computers (laptop) supply? From power supply to usb ground you mean?
ALso, I should make sure the USB ground is connected to the barrel socket ground, right?
If you could get me some tips on what to check here I would appreciate it

Thanks

TomGeorge:
Hi,
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Specifically the order and layout of your gnd wires.

Thanks.. Tom.. :slight_smile:

SORRY SORRY SORRY for the crappy schematic Im uploading...I used as you can see...my Paint Shop Pro to draw it, but I have no better means to do something nice right now
Hope it clarifies what I'm doing

Thank you

How do I check a ground leakage in my computers (laptop) supply?

Meter but they are not cheap.

You could try and connect a voltmeter between the unplugged in ground of the USB lead and the ground of your supply. Then put a 100K resistor across the meter and take the measurement again. It is not very accurate and it does not measure the leakage as such but the imbalance between the two supplies. But that is what is killing you. The moral of course is never plug in two mains powered systems when the voltage is on.

Are there other things on the same mains outlet? We once had a situation at a place I worked where we had a rack of 50 modems. While each individual modem was well within the leakage limits adding 50 to the same mains spur produced enough current and voltage to be lethal. These currents are induced in the signal ground lines by stray and indeed real capacatances in switched mode power supplies and you can often feel a tingle between say a grounded antenna screened lead and the ground of the antenna socket. If you read the TV manual it will tell you to connect up the antenna before applying any power.

If this is the case then you can try connecting the ground of your 12V supply to the mains ground as well as the ground of the laptop to mains ground. This will prevent the two grounds from being at different voltages.

Hope it clarifies what I'm doing

Well no, there is no power supply wiring shown and that is what you are having trouble with.

Somethign I was thinking...related to this. Shouldn't all the DC grounds (12V power supply, USB / computer ground...) be actually completly isolated one from the other?. Cause if they are all completly "floating", they would never "complain" when they are tied together. But if one is "derived" from a stable voltage, then it's tied to a certain potential, so if you tie it together with another one, there will be a current draw, right? I mean, I see more practical ensuring that all the DC grounds that power the board are "running free", totally isolated.

I just tested something. I just touched, with a voltage-tester screwdriver, both poles in my %100 chinese 12V power supply, the one I'm using to power my Arduino Mega. Guess what? It lights up, both poles...I don't feel current at all when I touch it, it must be weak, but there's some leakage from AC to the DC output in this crappy walwart...I may have gone too cheap on this one.
I have tried all the other walwarts in my house (phone charger, modem PS, switch PS, etc...and none of them lights up my screwdriver)

I will probably disassemble it and check how well isolated it is.

Thanks!

I just touched, with a voltage-tester screwdriver, both poles in my %100 chinese 12V power supply, the one I'm using to power my Arduino Mega. Guess what? It lights up, both poles.

That tells you nothing. The permitted leakage current is more than enough to light up a neon.

Shouldn't all the DC grounds (12V power supply, USB / computer ground...) be actually completly isolated one from the other?

Yes.

Cause if they are all completly "floating", they would never "complain" when they are tied together.

No. They don't complain, there is nothing wrong when they are connected together. However, when you connect them together while they are on they then share the same reference point and so there is some adjustment that takes place as the leakage current for both devices share a common point. This will cause some voltage transients on the supplies which I what I believe is killing your system. If you connect them together before you power things up you will have no problem, but you don't and you do.

edugimeno:
output in this crappy walwart...I may have gone too cheap on this one.

I don't feel current at all when I touch it

That was lucky!

Some people been killed by going too cheap. Most times unawaringly. The good thing is... you're ok.

I will probably have to switch to a different power supply then, this one doesn't even have the prong for the ground in the AC side. It's just one of those walwarts that use 2 prongs

I disassembled it and it had a CY2 capacitor between the rectified AC input and the DC ground. Supposedly to reduce interference. But it was also leaking too much AC into GND. I removed it. Now the scredriver barely lights up.