Atmega1284p Bootloader Problems

So I have a arduino uno using the atmega328p and am trying to burn a bootloader to a atmega1284p I've followed Arduino on ATmega1284P | maniacbug. The first time it seemed to work but when I tried uploading a program it didn't. So I tried burning the bootloader again, and have not been able to do anything at all.

This is the message I get: avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
Double check connections and try again, or use -F to override

I've tried messing with the reset using capacitors and resistors. etc. to no avail.

Please help.

What programmer are you using? Seems like it a connection problem, the programmer didnt read the device signature

I am trying to use the arduinoISP to burn the bootloader (arduino IDE)

I've tried many google searches and found nothing that helped.

I've wired and rewired it and checked it again and again to no avail.

I'm now getting this error:

avrdude: reading input file "C:\Program Files (x86)\Arduino\hardware\maniacbug-mighty-1284p-68ed99c\bootloaders\optiboot\optiboot_atmega1284p.hex"
avrdude: can't open input file C:\Program Files (x86)\Arduino\hardware\maniacbug-mighty-1284p-68ed99c\bootloaders\optiboot\optiboot_atmega1284p.hex: No such file or directory
avrdude: read from file 'C:\Program Files (x86)\Arduino\hardware\maniacbug-mighty-1284p-68ed99c\bootloaders\optiboot\optiboot_atmega1284p.hex' failed

Have you tried Nick Gammon's programmer sketch?

Try to read this:
http://forum.arduino.cc/index.php?topic=248513.msg1781191#msg1781191

So it seems as if I now can get the bootloader to burn correctly.

But when I try to upload code it doesn't work saying:

avrdude: stk500_paged_write(): (a) protocol error, expect=0x14, resp=0x64
avrdude: Send: V [56] @ [40] . [00] . [00] . [0c] [20]
avrdude: Recv:
avrdude: stk500_cmd(): programmer is out of sync

Note MCU pin 1 is blinking three times when reset seeming to indicate the bootloader is intact.

I am using Mighty 1284p 16Mhz using optiboot from maniacbug (Arduino on ATmega1284P | maniacbug)

Also I am using arduino IDE 1.0.5-r2

That sounds like it might be the baudrate of the bootloader doesn't match the baudrate stated in the boards.txt entry for the specific board you select?

breakthrough!!!!!!!!!!

If I press reset 1 to 2 seconds after I see uploading on arduino IDE it works!!!!!!!!!!!!!

Why is this and how can it be fixed?

That would indicate that DTR is not making it thru a 0.1uF cap to the Reset pin that is pulled up to 5V with a 10K resistor.
Can you confirm?

I tried removing the .1uF cap and connecting DTR to reset and it wouldn't upload.

What should I try?

DTR is a level, it must go thru the cap to make a reset pulse. The cap temporarily lets the signal go low, the 10K pullup brings it back high.

I've now tried a 1uF cap to see if it made a difference, but it didn't.

What would you recommend?

Any ideas?

What kind of USB>serial converter are you using?

This one

(FT232)

0.1uF, not 1uF.

Post your circuit, gotta be something else. Sure sounds like auto-reset not working tho if manual press of reset allows uploading.

ATmega1284P on a breadboard | maniacbug.wordpress.com/2011/1… | Flickr + switch on pin 9 that will pull it low when pressed. Is it important that all the connections to the arduino are unplugged, because they are.

I am using .1uF I just tried 1uf to see if it would make a difference.

After changing my bootloader to "the original mighty 1284p 16Mhz" I was able to periodically get a random successful upload. Now however I keep getting not in sync and protocol errors from avrdude. I've already tried reburning the bootloader.

Is there a 10K pullup resistor from Reset pin to +5? If there is, I can't see it. It's needed for Reset to recover to a good level after DTR pulls it low via thru the 0.1uF cap.