Author Topic: My ATmega16U2 chip caught fire  (Read 1445 times)

0 Members and 1 Guest are viewing this topic.

Offline Old GreyTopic starter

  • Newbie
  • Posts: 9
  • Country: au
My ATmega16U2 chip caught fire
« on: October 03, 2018, 09:47:53 am »
The 16U2 exploded on my MEGA2560. The MEGA was controlling a car EFI shield and some large current decided to GND through the USB into a laptop that was being powered by the same car battery.

I don't have much experience and don't know what I'm doing - only 2 years as a hobby - so I search errors, and what I can think of, and this is where I'm up to.

Not knowing what a 16U2 was - I found out latter it was a micro - I soldered in a new one.
I plugged it into a PC and nothing in Device Manager.
More reading and I found out it needed a driver - something DFU I think - so I loaded one - it says libusb0 - and now it sees it as ATmega16U2 device in Device Manager, but not as a MEGA driver in COM.
After more reading it looked like the 16U2 needed firmware so I used FLIP to load "MEGA-dfu_and_usbserial_combined.hex" from the IDE, and now it comes up as MEGA on COM20.
Going to IDE it seams to see it - Board Info comes up -, but it doesn't seam to actually communicate.
I tried to load Blink through USB, but it says :-
Quote
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_getsync(): timeout communicating with programmer
More reading and I try the Loopback test, and whatever I type in Serial Monitor comes back to the box below. I assume that the 16U2 is doing what it's supposed to do.
Thinking the 2560 is blown I load a blink sketch through the ICSP, and it works.
I test the traces between the 16u2 and 2560 with a DMM from pin to pin - this checks if the solder is cracked under the pin - and there is continuity.
I now test if TX straight out of the 2560 is working with the sketch below - someone else wrote this and told me what to do because I don't know what I'm doing. :)
Quote
void setup()
{
  Serial.begin(57600);
}

void loop()
{
  Serial.println("Hello world");
}
Hello World comes streaming out of the USB when I select baud 500000. I think the TX on the 2560 is working.
Next I test the RX - again someone else wrote this - that I think is supposed to latch the on-board LED when you enter a character into Serial Mon.
Quote
void setup()
{
  Serial.begin(57600);
  pinMode(LED_BUILTIN, OUTPUT);
  digitalWrite(LED_BUILTIN, HIGH);
  delay(3000);
  digitalWrite(LED_BUILTIN, LOW);
}

void loop()
{
  if(Serial.available()>0)
  {
    Serial.read();
    digitalWrite(LED_BUILTIN, digitalRead(LED_BUILTIN));
  }
}
I tried the RX sketch through the USB and every entered character makes the RX LED flash, but that's all.

Would there be anything else that might not make me come to the conclusion that the RX on the 2560 is blown? Ideas welcome, if explained in dummies English :)

The only thing I can't do is load the correct hex file(Arduino-COMBINED-dfu-usbserial-atmega16u2-Mega2560-Rev3.hex) into the 16u2, because FLIP corrupts it and I don't have a hope of working out avrdude. I don't think this would make a difference because the 16u2 looks to work through the USB.
Failed FLIP video -


Thanks
 

Offline Sceadwian

  • Supporter
  • ****
  • Posts: 55
  • Country: us
  • Beware those that tell you the way the world is.
Re: My ATmega16U2 chip caught fire
« Reply #1 on: October 04, 2018, 03:44:29 am »
Given the cost of a new 2560 you've probably already spent more time determining the failure than it's worth. Even as a curious hobbyist I would just chuck it and get a new one. Right after you figure out what blew it up in the first place :> or something more fun like an ESP32
-Because I be, what I be. I would tell you what you want to know if I could, mum, but I be a cat. And no cat anywhere, ever gave anyone a straight answer.-
 

Offline Ian.M

  • Super Contributor
  • ***
  • Posts: 12860
Re: My ATmega16U2 chip caught fire
« Reply #2 on: October 04, 2018, 05:54:06 am »
What blew it up was a ground loop in a chassis ground automotive environment.  All it takes is ONE loose or corroded ground screw, or dirty connector pin, and the  USB cable ground ended up carrying the supply current of the laptop.   You are lucky - a little extra resistance at the engine block ground strap connections, and both the laptop and Arduino could have burned the next time you keyed the starter, and maybe you 'd even loose the vehicle to the resulting wiring fire.

*NEVER* trust that two grounds connected at different points to a vehicle are at the same voltage.   Don't connect them by thin wire, and if you connect them at all, consider the worst case current that ground strap may have to carry.   Optoisolation is your friend . . . .
 

Offline Old GreyTopic starter

  • Newbie
  • Posts: 9
  • Country: au
Re: My ATmega16U2 chip caught fire
« Reply #3 on: October 04, 2018, 09:28:55 am »
The 16u2 MEGA cost a bit more than the CH340  ;), but yeah it probably is a bit excessive. At the time I didn't know that the 16u2 was a micro that need a bootloader - I didn't know I would have to learn all that from scratch afterwards :o -, so it seamed like it was just going to be a simple mechanical swap of a $4 chip.

It's weird it blew up because it was running fine on the inverter I put in the car. I thought 240V in a car was a bit dangerous so I bought one of those cheap direct power supplies that run from the cig lighter, but on the first day I noticed the PS getting hot. It was working the night before, but when I plugged it in the next day it instantly blew tracks on the shield and put a crater in the 16u2 :o. Luckily this was a parallel EFI fitment so I was able to plug in the std ECU and get home.  :)

I was just wondering if my methodology that points to the 2560 blown is correct, incase there is anything I missed that might get it working again.

« Last Edit: October 04, 2018, 09:31:29 am by Old Grey »
 

Offline Rerouter

  • Super Contributor
  • ***
  • Posts: 4694
  • Country: au
  • Question Everything... Except This Statement
Re: My ATmega16U2 chip caught fire
« Reply #4 on: October 04, 2018, 09:47:08 am »
As you had current flow, you had voltage come in somewhere, possibly even an open circuit ground on your laptop charger, this can happen in older cars where the cigarette lighter socket sides are oxidized from evaporated cleaning agents over the years,

The fact you got him programmed is promising, as I am planning on making some field upgradable devices using him,

But yes, I would suspect your 5V suddenly became 19V, or something like that, and popcorn happened,
 

Offline NiHaoMike

  • Super Contributor
  • ***
  • Posts: 9016
  • Country: us
  • "Don't turn it on - Take it apart!"
    • Facebook Page
Re: My ATmega16U2 chip caught fire
« Reply #5 on: October 04, 2018, 01:46:24 pm »
The 16u2 can be used as an Arduino of its own.
https://github.com/NicoHood/HoodLoader2
Cryptocurrency has taught me to love math and at the same time be baffled by it.

Cryptocurrency lesson 0: Altcoins and Bitcoin are not the same thing.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf