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: Read/Write from/to NAND (AT91SAM9260EK)
PostPosted: Fri Feb 15, 2008 10:55 am 
Offline

Joined: Tue Jun 26, 2007 6:27 pm
Posts: 81
Hello,

could anybody explanin me, how I could read/write my NAND Flash if Linux is running ?

Is there a generic driver avilable or still included ?

Maybo someone could add some SourceCode...

Thanks

Manuel


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 16, 2008 2:18 am 
Offline

Joined: Mon Apr 16, 2007 6:34 pm
Posts: 41
Location: Fargo, ND, USA
If you want to write to straight to the Flash, you can use the character devices /dev/mtd?. You can just use dd or roll your own program. When using dd you need to specify a blocksize equal to the erase block size, and use the conv=sync option.

Example (for dataflash, NAND is similar):
Code:
dd if=/tmp/u-boot.bin of=/dev/mtd0 bs=1056 conv=sync seek=32


If you don't need to write to a specific location (i.e. you are not writing something like a firmware image), use jffs2 instead.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Feb 19, 2008 6:21 pm 
Offline

Joined: Wed Feb 14, 2007 11:17 am
Posts: 67
Beware of the bad blocks :
http://www.linux-mtd.infradead.org/faq/ ... L_nand_srw


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: Google [Bot] 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: