Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: SAM3U-EK: Writing flash0 AND flash1 with sam-ba?
PostPosted: Thu Nov 17, 2011 11:40 pm 
Offline

Joined: Thu Nov 17, 2011 11:25 pm
Posts: 1
Hi,

I need to write 200KB of code to a SAM3U4E.
I have made an .lds-file that distributes the code over flash0 and flash1. But how do i program both flash?

Is there some good tool for breaking the .elf file into two separate .bin-files?

Regards

Mats


Top
 Profile  
 
 Post subject: Re: SAM3U-EK: Writing flash0 AND flash1 with sam-ba?
PostPosted: Fri Nov 18, 2011 10:14 am 
Offline

Joined: Tue Jul 13, 2010 12:54 pm
Posts: 29
If the binary was correctly generated, you should be able to use samba to write the whole file to flash 0. Flash0 and flash1 is contiguous. It is possible with SAMBA to write a file larger than 128k to flash0. The section larger than 128k will then be put in flash 1.

If you really want to hard seperate the binaries, it is also possible to compile 2 projects, with the output elf of the first project as an input to the second compilation so that the second binary/program can make use of the first ones functions. The first binary/program will unfortunately then not have access to the functions of the second binary.


Top
 Profile  
 
 Post subject: Re: SAM3U-EK: Writing flash0 AND flash1 with sam-ba?
PostPosted: Fri Nov 18, 2011 4:59 pm 
Offline

Joined: Sat Oct 30, 2010 6:04 pm
Posts: 574
Presumably you could just use objdump, and have it generate a binary or hex file. Either could then be subdivided into the two regions of interest.

Writing a splitter in C should be a relatively trivial task.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: