Pages: 1 [2] 3 4   Go Down
Author Topic: Bootloader compatibility  ATmega 1280 and 1284P  (Read 8166 times)
0 Members and 1 Guest are viewing this topic.
Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I finally got the ICSP connection working reliably, and the arduino18 environment to burn the bootloader.  I successfully uploaded the ADAboot loader with the modifications and the compiler optimizations ChrisS linked to.  I however do not know if it is working, as the LED does not blink.  Also I have not tried to actually upload any code to the device either. Ill get to work on this more tomorrow but thats all for now.
Logged

Dresden / Germany
Offline Offline
Sr. Member
****
Karma: 4
Posts: 451
Entwicklungsklaus
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

mmh, ok... gratulation to this step.

I ask because the bottom of the link says:
"RESOLVED: I modified the optimization from -O2 to -Os and NO ERRORS! and now the bootloader is working (led flashes correctly) smiley-grin"

you say nothing flashes...
also in your LAST posting with commandprompt, there is no such optimization switch...

I hate to say....mmh, are you shure about your ledwiring?
Have you checked/wired ResetPin?

In my opinion, it should work already if you patched files in 1284p Hardarefolder like for 644p.

Check this to be sure:
http://www.robotcraft.ca/webshop/images/projects/arduino-0011-core-visual-diff-modded-vs-original_2.gif

This is patch modification for 644p... by Robocraft/(maybe NYC Resistor).

mmh, i don't have checked fuses already... please recheck them...

i will do my checks if 1284p have arrived... *angry* it seems that I have choosen a real real real slow slow company for selling me 1284p.  :|

I don't know if Adaboot needs some special Hardware thingys around mcu to work/startup?

For today, I wish you good luck... hope to hear more good news from you smiley

Greetings ChrisS

« Last Edit: May 30, 2010, 01:25:08 am by ChrisS » Logged

Sturmfabrik - mediale Dienstleistungen
www.sturmfabrik.de

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

After much frustration I have tracked all my issues down to a breadboard with many faulty junctions....

I did end up getting the bootloader to blink the LED again a bad junction. This is to say the least frustrating.  I have not been able to upload code as I am having trouble finding good connections...
Logged

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok here is were I am.  I have it so that arduin 18 is able to burn the boot loader correctly, and the status LED does indeed blink while it is in the boot loader however the bootloader does not work.  The code downloads and during the verification process all 0xFF is returned. with the modified adaboot loader that chrisS linked too.
Logged

Dresden / Germany
Offline Offline
Sr. Member
****
Karma: 4
Posts: 451
Entwicklungsklaus
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

0xFF isn't right I think....

Seems you got clock or connection problems....

Check clock Fuses / connection... I think Fuses maybe the Problem...
I know... blinking works...

I got much 0xFF's while testing with 644P.... and the answer where in my task that I used wrong Capacitors for Clock-Quarz. I used micoFrard not Pico... that happend by me.

Checkit... it may help you.

Try the latest AVRStudio for test to burn Bootloader... without IDE... still supports 1284p.


Greetings ChrisS
« Last Edit: May 31, 2010, 02:56:36 am by ChrisS » Logged

Sturmfabrik - mediale Dienstleistungen
www.sturmfabrik.de

Dresden / Germany
Offline Offline
Sr. Member
****
Karma: 4
Posts: 451
Entwicklungsklaus
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

mmh, ok... i read again...

you are sure that you edited make file in bootloaders subdirectory...
to the right LDSECTION?
Quote

# Makefile for ATmegaBOOT
# E.Lins, 18.7.2005
# $Id$


# program name should not be changed...
PROGRAM    = ATmegaBOOT_644

# enter the target CPU frequency
AVR_FREQ   = 16000000L

MCU_TARGET = atmega644
LDSECTION  = --section-start=.text=0xF800 has to be a higher value... don't now the right adress....


Greetings ChrisS
« Last Edit: June 01, 2010, 06:23:59 am by ChrisS » Logged

Sturmfabrik - mediale Dienstleistungen
www.sturmfabrik.de

USA
Offline Offline
Full Member
***
Karma: 2
Posts: 213
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Steve S:

What 1284 board are you using?

Mark
Logged

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

@ChrisS

Nope did not make that change. Ill have to give it a try.
I'm going to see if the datasheet has anything to say on this...
Logged

Dresden / Germany
Offline Offline
Sr. Member
****
Karma: 4
Posts: 451
Entwicklungsklaus
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The thing is... Bootloader Position in Flash is in relation of Flashsize at all.

So the Bootloader has to be on a specific position in flash to get working.

This is a information got on the first posts i posted.

Quote
UPDATE 2:
I found that maybe the problem was "simply" the different LDSECTION value that I have to change for the 1284P.
So, as the datasheet say, for a boot size of 1024 words (2kbytes) the boot reset address is 0xFC00 then the LDSECTION will be LDSECTION = --section-start=.text=0x1F800 (0xFC00 x 2 = 0x1F800)
The value of 1F800 is even confirmed calculating it starting from the flash size (128k = 131072 bytes - 2048 bytes = 129024 bytes = 0x1F800)

Here the poster calculated 1F800.... for a 2048 Bytes Bootloader... i think with -Os parameter we should get 2048 Bytes....

If you don't have any positive results... maybe you think about UsbAspLoader... it's a Bootloader which emulates the Usbasp-Programmer for progranmming Mcu itself.... so you are able to boot, and use the ide to programm your sketches in Flashmemory like you want to.

Disadvantage, cause of use of Digitalpins instead of USART you arne't able to use virtualcomport-Communication....

For simple Programming purposes it should do the job.

UsbAspLoader ist a v-Usb Projekt (ArduinoCompatible) to get rid of FTDI (etc.) Chips... to include softwareusb directly inside of the mcu Bootloader....

Hope it helps a little bit to get further....

Greetings ChrisS

My 1284p aren't arrived yet... *little bit angry*

Logged

Sturmfabrik - mediale Dienstleistungen
www.sturmfabrik.de

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well I can program the chip just fine with the ICSP connection. Its just the bootloader thats giving me issues. If I could easily use the arduino environment with a programmer I would be happy.  Still I would like to get the bootloader working, I have gotten no further...
Logged

Dresden / Germany
Offline Offline
Sr. Member
****
Karma: 4
Posts: 451
Entwicklungsklaus
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

try the LDSection.....

ok, if you want to use the ide to programm... have a look at UsbAspLoader... again.... it is a bootloader which emulates a programmer to allow programming via IDE directly to the chip itself without external FTDI or something like this.

Greetings ChrisS
Logged

Sturmfabrik - mediale Dienstleistungen
www.sturmfabrik.de

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes I was messing with the LDSection but I never got anything that functioned. So i decided not to report my failures.

I will have to look at the UsbAspLoader though I had forgetten you can change the programmer in the board.txt...
Logged

Nottingham, UK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 90
Wait! Don't touch that wire...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Mark S

It isn't on a board (yet), unless you count a breadboard....
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 1
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Have you made any further progress with this? I had been following the thread, but no sign of updates for a while - didn't look like you were too far away! Extra hardware serial ports would be really useful for me, without the unnecessary expense of a mega, and the 1284 would have more RAM than a sanguino.
Thanks!
Logged

Michigan, US
Offline Offline
Full Member
***
Karma: 3
Posts: 148
Go Huskies
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I do plan on trying again but I haven't had time to mess with it as of late.  Id probably be more apt to try if I had a sanguino board to use this on and not the flaky breadboard I have been using (keep getting loose connections ect its a very very cheap breadboard smiley-wink ).
Logged

Pages: 1 [2] 3 4   Go Up
Jump to: