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  [ 57 posts ]  Go to page 1, 2, 3, 4  Next
Author Message
 Post subject: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jun 28, 2010 3:35 pm 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
Hi!

We made a custom AT91SAM9G20 board. On this board we use a Serial Flash (SST25VF032) because all Atmel Flashes are out of stock. Now we managed to get SAM-BA to work with this but the bootstrap doesn't seem to be able to use this Flash. Has anyone experience with this case? Maybe someone use a AT25XXX or AT26XXX for booting and can help?

Thank you very much!

Best regards,

Torben


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jun 28, 2010 7:56 pm 
Offline

Joined: Wed Jan 09, 2008 5:09 pm
Posts: 186
Location: Mounds View, MN
More than likely you will have to modify the dataflash version of the bootstrap code to look for and load an SPI flash instead.

_________________
Tim Barr
Multitech Inc.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Tue Jul 20, 2010 7:55 am 
Offline

Joined: Sat Jun 13, 2009 5:50 pm
Posts: 43
Why you didn't use NAND Flash to store AT91Bootstrap image ?
The NAND FLash chips are very available and cheap.

Regards.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 8:45 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
We have a NAND Chip onboard. But in a NAND memory bits can get errors without warning and you need an algorithm to correct such failures. This algorithm has to be stored in the bootloader. Since it makes no sense to store it on the NAND itself we want to use a serial flash for it to solve this possible problem.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 9:34 am 
Offline

Joined: Thu Jul 08, 2010 9:36 pm
Posts: 28
If the ROM bootstrap does not recognize that serial flash you are out of options IMHO.

I have realized, that for reliably booting systems on AT91SAM9 one needs to use the AT91SAM9XE Versions with embedded NOR flash or have at least a small NOR flash (256KB would do) attached to nCS0 and wire BMS to start execution from there.

Or you could add a microSD card holder to the design and boot from there.

But I am afraid your design is already done...

If you are happy with 190 MHz you could switch to the XE Versions.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 9:37 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
Our design is already through prototype testings and we will have to write the boot code for the serial flash ourselves. It is possible to implement it and we will have to do it. Unfortunately it is ~1 week of work which was not planned.

I do not understand why Atmel sells some serial flashes as dataflash, this started the confusion and the whole problem.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 9:39 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
One more thing:

We have a micro SD card holder, but it is later in the boot order than the nand flash...

To change this one has to implement a sd boot from uboot, because this isn't implemented afaik.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 6:38 pm 
Offline

Joined: Thu Jul 08, 2010 9:36 pm
Posts: 28
Humm, where do you intend to store the boot code?

I recently added SD/MMC support for U-Boot on AT91SAM9xxx. Its not in mainstream yet but patch is in the U-Boot mailing list.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Fri Jul 23, 2010 7:57 pm 
Offline

Joined: Wed Jan 09, 2008 5:09 pm
Posts: 186
Location: Mounds View, MN
TKL wrote:
We have a NAND Chip onboard. But in a NAND memory bits can get errors without warning and you need an algorithm to correct such failures. This algorithm has to be stored in the bootloader. Since it makes no sense to store it on the NAND itself we want to use a serial flash for it to solve this possible problem.


Check the data sheet for your NAND Flash. Typically the first block is guaranteed to be error free for 1000 cycles for just this reason, since most bootloaders are too small to have ECC support. Also, NAND flash errors are almost always generated from an erase, so if you don't change the bootloader in the field, you will reduce the chances of the first block having an error in the field.

_________________
Tim Barr
Multitech Inc.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 8:59 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
I will take a look in the datasheet. But I cannot guarantee that the bootloader will not have to change in the field as the firmware might and we have to be able to update everything in the field. So even 1000 Cycles might not be enough, although it is quite something. But it is a very good tip, I didn't knew that.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 9:20 am 
Offline

Joined: Thu Jul 08, 2010 9:36 pm
Posts: 28
The first sector is usually 128 KB in NAND. Its too small for U-Boot, but it is large enough for something dedicated that can load the real thing from NAND using ECCorrection and looking for it in several alternative places.

And when you need to plan to change the _bootloader_ more than 1000 times in the field, something seems extremely wrong in the approach...

Reinhard


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 9:26 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
Of course we do not plan to do it more that 1000 times. It should be far more than enough...


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 9:29 am 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
I checked the datasheet of the NAND and there is nothing about a special block. It just says 100000 program / erase cycles per block with ECC.


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 1:03 pm 
Offline

Joined: Thu Jul 08, 2010 9:36 pm
Posts: 28
What is the exact type of the NAND?


Top
 Profile  
 
 Post subject: Re: AT91SAM9G20 - Bootstrap with SerialFlash - how do you do it?
PostPosted: Mon Jul 26, 2010 1:10 pm 
Offline

Joined: Thu Feb 11, 2010 7:47 pm
Posts: 29
Numonyx NAND02GW3B2D


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 57 posts ]  Go to page 1, 2, 3, 4  Next

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Bing [Bot] and 2 guests


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: