Mega2560

USB AVR Programmer and SPI interface. Adafruit's USBtinyISP.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
newhobby
 
Posts: 12
Joined: Sun Dec 05, 2010 10:08 pm

Mega2560

Post by newhobby »

Hi,
I have a USBtinyISP burner and was wondering if there is any way to fix this issue:
http://www.arduino.cc/cgi-bin/yabb2/YaB ... 1278384063
It seems the burner can't be used to burn 2560 bootloaders.
I've been trying and always get the same error:
avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x3e000
0x0d != 0xff
avrdude: verification error; content mismatch
I can't verify that the reason is the burner as I do not have another one.
I can tell you that I can burn 328P just fine.

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm

Re: Mega2560

Post by adafruit »

sorry, it wont work, the new 2560 requires a different programming method!

User avatar
vmarguerie
 
Posts: 4
Joined: Tue Mar 08, 2011 12:12 pm

Re: Mega2560

Post by vmarguerie »

Hi,

as the USBtinyISP doesn't work with the mega2560, is there another product that can do this upload job ?

In fact, i'm looking for a solution that allows me to upload a sketch other than with the native usb port, because sometimes, due to the huge serial trafic I have in my sketch, it becomes very hard to upload.

My PC is a laptop, so I can't use parallel programmer...it would have been so simple :?

Regards

User avatar
kscharf
 
Posts: 277
Joined: Wed Sep 10, 2008 10:29 am

Re: Mega2560

Post by kscharf »

Check the Arduino support pages on the Arduino web site, there is a way to use one Arduino board as an USB ISP programmer for another.
The USB tiny *might* actually work to program devices >64K. There is a patch to AVRdude that disables the auto-verify function which seems to be what fails due to the firmware in the USBtiny. The device may actually program but the USBtiny can't perform the verify beyond 64K.
Needless to say there is some risk in using the device without the verify function! Otherwise just buy an AVRispMKII or a clone of one. The real deal will cost you about $35 US from Atmel. I now have both the USBtiny and the AVRispMKII myself having started using atmega1284p chips.
See the bottom of this page: http://blog.lincomatic.com/?p=548

User avatar
westfw
 
Posts: 2008
Joined: Fri Apr 27, 2007 1:01 pm

Re: Mega2560

Post by westfw »

I think arduinoisp has problems beyond 128k as well.

The thing is, avrdude might "cheat." Both the stk500v1 (arduinoISP) and usbtinyisp protocols only handle 64k (bytes, words... doesn't matter) in their "bulk program" command. But they also support a "raw spi command" command. So (at least in theory), AVRdude can program ANY location by sending a series of raw spi commands ("Load extended Address byte", ("load program memory page low byte", "Load program memory page high byte") for each word, "write program memory page") - a bunch of bytes and communication "exchanges" for each byte of the bootloader, instead of approximately 1 byte, but it still might be fast enough for an 8k bootloader.
I think that this is how USBTiny can apparently program the 2560 bootloader, but not verify it...

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Mega2560

Post by adafruit_support_rick »

Have you thought about JTAG? That Atmel JTAGICE 3 is nice
http://store.atmel.com/PartDetail.aspx?q=p:10500269

User avatar
kscharf
 
Posts: 277
Joined: Wed Sep 10, 2008 10:29 am

Re: Mega2560

Post by kscharf »

driverblock wrote:Have you thought about JTAG? That Atmel JTAGICE 3 is nice
http://store.atmel.com/PartDetail.aspx?q=p:10500269
It's possible to add the jtag as a bootloader for arduino by editing the config files.

Locked
Please be positive and constructive with your questions and comments.

Return to “USBtinyISP”