Fried Arduino Mega and my laptop - what did I do wrong ?

Yes, when there is no power.
So you need to put a diode between 12V and Vin

That wouldn't explain this though:

USB ports are amply protected against the risk of sourcing excess current. Shorting Vbus to GND is the typical kind of abuse that any USB host bridge protects against. The general failure handling consists of the port being taken offline for it to immediately being brought back up as the overcurrent condition is lifted.

What does fry a USB hub/host is applying a voltage to it that exceeds its maximum ratings; anything above approx. Vbus + 0.6 will be (very) risky.

1 Like

I just responded to another topic where the person had 3.3V connected to Vin. It killed his laptop and the Uno.
You assume too much about how manufacturers treat USB ports.

So if i understand this correctly. If i want to do it the easiest - i will connect only one of them each time - so i will connect the arduino without the 12v but with the USB or i will connect the arduino without the USB but with the 12v
Right? This shold be ok(?)

That is probably what killed the Mega and the laptop.

but why is that? when powering the Arduino from the USB the max voltage it gets is 5v and there is no other power source connected to it. Vin is disconnected completely i can also disconnect the ground pin by breaking the legs of another pin headers siting on the original pin headers. am i missing anything?

Maybe I'm missing something. Do you mean you disconnect the shield from the Mega?
How do you disconnect Vin?

i can also disconnect the ground pin by breaking the legs of another pin headers siting on the original pin headers.

Never do that.

i will clarify :
option one - Arduino is connected to the shield - but Vin pin is disconnected completely, pins not touching. USB is connected to the Arduino.
option two - Arduino is connected to the shield - with Vin pin is connected, pins touching. USB is not connected to the Arduino.

all the other pins in the schematic are connected.

this shield is something i created : here are some photos :


i can add another layer of pin headers like those :
prt-11376_SPL
and break some of the pin for Vin so they will be disconnected.

thank you for putting the time :slight_smile:

That would be the sahest way of doing it but makes debugging you program very difficult.

another thing i can do - i can cut the 5 volt line in the USB cable - this way, if i understand correctly , only data will be transported, i will be able to debug and also no risk? like here :build-a-simple-isolator-for-externally-powered-arduinos

I've never tried doing that, so I personally can't say that it's safe.
The article you linked to offers it as a solution when connecting a voltage to the Arduino 5V output which is something I don't recommend.

There may be other problems with your shield that are not apparent by just looking at the schematic. Connecting 12V to Vin with the USB connected should not be a problem provided the 12V is clean and stable without glitches and you never connect the unpower shield to the mega with the mega powered by the USB

No matter what you decide I still recommend the diode.

1 Like

@xepo23 ,

Your other topic on the same subject deleted.

Please do not duplicate your questions as doing so wastes the time and effort of the volunteers trying to help you as they are then answering the same thing in different places.

Please create one topic only for your question and choose the forum category carefully. If you have multiple questions about the same project then please ask your questions in the one topic as the answers to one question provide useful context for the others, and also you won’t have to keep explaining your project repeatedly.

Repeated duplicate posting could result in a temporary or permanent ban from the forum.

Could you take a few moments to Learn How To Use The Forum

It will help you get the best out of the forum in the future.

Thank you.

@xepo23 (and anyone else),
My apologies, I accidentally made your topic into a personal message, which I have now reverted to being a public topic. I could not see which category it was originally in, I have put it in Project guidance.

Sorry for the mistake.

Hi,

I created another topic because I believed that what I asked there is different. Here, I try to understand what I did wrong in terms of power, and there I tried to understand if there is a chance to save the board in any way. But per your request, I will just post it here:

Unfortunately, I connected my Mega to a powered shield and there was a spark. Now the Arduino doesn't work.

When I connect the USB to the Arduino, the "on" LED turns on and the "L" LED turns on but then dims until it turns off. On my PC, I can see the Arduino on COM4, but the uploads fail every time, saying:

avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_getsync(): timeout communicating with programmer
Failed uploading: uploading error: exit status 1

I tried doing a loopback test, but it failed.

Any suggestions on how to move forward from here?

Thanks.

1 Like

i tried that, i opened the USB cable and cut the 5V pin but for some reason now the laptop i used doesn't recognize the Arduino. the Arduino was fed with power via the Vin pin.
all else the same...

Does it work if you supply power from the USB?

By "powered shield", do you mean the circuit of your own design?
If so, the way forward is to carefully assess that design to figure out how it exactly violates the operating conditions of the Arduino. My guess is still that 12V or 24V ends up on one or more of the Arduino pins where it shouldn't be.