Pages: [1]   Go Down
Author Topic: Burning bootloader directly on Arduino Uno board  (Read 664 times)
0 Members and 1 Guest are viewing this topic.
Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I managed to kill an Arduino yesterday by plugging a wire into a pin from another device without connecting the grounds first. The Mega328 got very hot and made a loud crackling sound. smiley-sad

So I pulled out a spare Mega328 chip and plugged it into the board, hoping it was just the chip that was dead. I connected up my USBtinyISP and tried to program it but all I get was the dreaded: "avrdude: initialization failed, rc=-1"

After a lot of messing around I pulled the chip out and put it on a breadboard. It programmed perfectly. Put it back in the Uno, it fails to program. Back to the breadboard, works perfectly again...

Can anybody explain this? I thought I should be able to just connect to the ISP header and program it. I've tried different power, check the PCB connections from ISP connector to chip, nothing. I tried another Arduino Uno out of paranoia, same thing.

Has anybody else managed to program an Uno via the ISP header?

PS: The Uno is fine with the new chip.



« Last Edit: June 23, 2013, 05:38:41 am by fungus » Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 203
Posts: 8720
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, I've been able to burn a bootloader on the Arduino UNO (R2) with a USBasp ISP device.  Perhaps one of the lines necessary for ICSP has gotten fried.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, I've been able to burn a bootloader on the Arduino UNO (R2) with a USBasp ISP device.  Perhaps one of the lines necessary for ICSP has gotten fried.

That's what I thought but I tested the lines between ISP connector and the Mega328 socket and they seemed OK (and it wasn't one of those pins I killed, it was digital pin 3).

I also tried a different Arduino Uno, same result.

I'm sure somebody must have done it of there wouldn't be a connector on the Uno PCB. It just doesn't work for me and I have no idea why. I use the programmer almost on a daily basis (and it managed to program the exact same Mega328 chip on a breadboard) so I don't see how it's that.

It's a mystery...
Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 203
Posts: 8720
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Have you removed all shields and other hardware connected to the UNO?

Maybe the PIN 1 marker on the ICSP header is in the wrong place and you had the connector on backward?
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Have you removed all shields and other hardware connected to the UNO?

Of course.

Maybe the PIN 1 marker on the ICSP header is in the wrong place and you had the connector on backward?

Nope. I tested all that a dozen times.
Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26570
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Maybe reset pin fried on the 16U2 and is preventing programming. Its the only thing in common between the 2 device re: ICSP programming.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Maybe reset pin fried on the 16U2 and is preventing programming. Its the only thing in common between the 2 device re: ICSP programming.

It seems to be working just fine with the new chip...

Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Maybe reset pin fried on the 16U2 and is preventing programming. Its the only thing in common between the 2 device re: ICSP programming.

It seems to be working just fine with the new chip...

Aha! Some light...

Ok, I just got my other Arduino Uno out to give it another try (check if I really am going insane):

I used avrdude to look at the device info and it worked! I could swear it didn't work earlier, but whatever.

I went back to the board I zapped and I get "avrdude: initialization failed, rc=-1"... so there must be something bad on the board. I held down the reset button, ran avrdude again and it got the device signature. Looks like CrossRoads is right, something is preventing the reset line from going low when I use the programmer.

The RESET connection from the ISP header to the Mega328 chip is good, it must be something else.


Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26570
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

On the bad board, start checking the 16U2 - does the loopback test work?
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Rapa Nui
Offline Offline
Edison Member
*
Karma: 60
Posts: 2066
Pukao hats cleaning services
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Is there a diode from reset to Vcc (maybe shorted)..?
« Last Edit: June 23, 2013, 03:28:10 pm by pito » Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26570
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

That sounds good too. Diodes are usually pretty durable, but anything can happen.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Valencia, Spain
Offline Offline
Faraday Member
**
Karma: 144
Posts: 5378
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

On the bad board, start checking the 16U2 - does the loopback test work?

I can upload/run sketches no problem, so I guess loopback would work too.

AFAICT the Arduino is working perfectly (apart from not being able to burn bootloaders via the ISP connector).
Logged

No, I don't answer questions sent in private messages (but I do accept thank-you notes...)

Pages: [1]   Go Up
Jump to: