Go Down

Topic: Re-burning bootloaders (Read 4 times) previous topic - next topic

Onions

Today, I received an ATMEGA 328 in the post from RS. I found the hardware files for the 328 (without an external crystal) here:
http://arduino.cc/en/Tutorial/ArduinoToBreadboard
It said that I needed to burn a bootloader to program it, so I did. (I burned the bootloader to use it with the internal oscillator). I then connected it up how they did in the diagram, and it did not work. As I already had the bootloader on it, but I could not program it on the breadboard, so I put it into my arduino to program. It still did not work, so I tried to burn a new bootloader to it. This did not work either. I successfuly managed to burn the no-crystal bootloader onto it, using the arduino as an ISP. I just cannot program it now. >:-(
Is there any way to burn a new bootloader onto it, or get it to work some other way?

Thanks everyone.
Onions.
My website: http://www.harryrabbit.co.uk/electronics/home.html Up and running now! (Feel free to look round!) :D

alparent

This is what I had to do to get it to program.

After you hook up your breadboard to RX and DX and removed the chip from you main board, connect a wire from the pin 1 on the main board (now empty) socket (not pin 1 on the headers.....on the chip socket)and connect it to the pin 1 on your on-breadboard chip.


Onions

Quote
After you hook up your breadboard to RX and DX and removed the chip from you main board, connect a wire from the pin 1 on the main board (now empty) socket (not pin 1 on the headers.....on the chip socket)and connect it to the pin 1 on your on-breadboard chip.

That makes sense, as pin 1 is the reset, and we will need to reset the IC to program it.

Just tested it, and it still does not work. Thanks anyway though!
Onions.
My website: http://www.harryrabbit.co.uk/electronics/home.html Up and running now! (Feel free to look round!) :D

johnwasser

What is the exact error message you are getting when you try to program the chip?

I thought my ATmega168 chips were fried because I always got a verification failure programming the lock bits.  Turns out that AVRDUDE was resetting the Arduino that was supposed to be acting as an ISP and talking to the Arduino bootloader instead of the ArduinoISP sketch.  :(  The fix was to add a capacitor (2.2ufd in my case)  from Reset to Ground to keep AVRDUDE from resetting the Arduino.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Coding Badly

Once you have the ArduinoISP connected, instead of burning a bootloader, try to upload a simple Sketch like Blink.  Don't forget to add an LED + resistor on pin 13.  If that works then you've proven that your ArduinoISP really is working the way it should.  Reburn the bootloader.

When Blink + burning the bootloader works, I think these are the remaining possibilities...

1. You didn't get RX + TX connected correctly (loose wire, swapped).

2. You didn't get the Arduino processor "disabled" when you tried to upload a Sketch to the target.

Go Up