Reading from NAND through software

Hi,

I'm trying to figure out now to setup my device where I store some specific device data in NAND and then have my software read those values when running. I already have my data stored in NAND, I'm just trying to figure out how to read it in my software. In poking around with Google, I found references to this web page:

http://patchwork.ozlabs.org/patch/27115/

which looks like development on a nice C file to access NAND. When booting, I see the following buried in the startup sequence:

omap2-nand driver initializing
NAND device: Manufacturer ID: 0x2c, Chip ID: 0xb1 (Micron NAND 128MiB 1,8V 16-bit)

so it looks like I have the foundation in place. But I have no idea what is the "Beagle Board way" or "Linux way" of reading from NAND?

-Stevo Brock
  Sunset Magicwerks

This should get you started:

http://elinux.org/BeagleBoardNAND

I agree with Pawel, the best thing for you is to read that wiki.
Anyway if you just want to store data on nand and you’re running linux, let’s say Angstrom distribution, you already have a partition to read/write data in your nand device accessible from linux, you just have to mount it and give it a filesystem.
With this three lines from the wiki should be enough:

root@beagleboard:~# cd /mnt
root@beagleboard:~# mkdir nand
root@beagleboard:~# mount -t jffs2 /dev/mtdblock4 /mnt/nand

Now you should be able to read/write data to /mnt/nand

If you want to do it permanently remember to modify /etc/fstab accordingly.