NAND Erasing

NAND does clicking up select down then up three clear completely the nand?
I think it erases NOR since it deletes ithink tinybooter and the firmware. Then there is an option to erase in microsoft mdf deploy. Does this erase the NAND or just the 8 MB user managed data?
I have a problem in that the program creates a config file in NAND, and I need to erase it so I can start over.
How does one do this? Thanks

Why not use your c# software to overwrite the file on NAND?

As GUS said you can owerwrite file on NAND or delete it:

if (File.Exists(file))

Also you can format NAND from code if you want something like this:

PersistentStorage ps = new PersistentStorage("NAND");
VolumeInfo nand = new VolumeInfo("NAND");
nand.Format("FAT", 32, true);

I am trying to track down a non repeatable error. IE Random. Erasing the NAND completely would eliminate a possibility that the fault is in older config versions. Also am interested in learning the background behind different processes, for future development. thanks in advance.

Sorry about the insistence, but when using the development kit and you hold down the three buttons does this erase the NAND file area? I recognize the validity in your statements but at this time I don’t have the technical know how to implement the methods you recommend. In the future I hope to.

You can be 100% shure that everything is erased only if you:
With holding buttons press and release RESET button
Release UP&SELEC&DOWN buttons and follow instructions on LCD.
3x press UP button to erase all data. Wait to complete and then RESET. Then you can upload FW and you will have empty device(Use ChipworkX Updater)…

You can also download SAM-BA from the atmel site and erase the nand flash with it:

Go to the NAND tab (top rectangle), first click execute (bottom rectangle) while it says Enable nand flash and then change the dropdown box to Erase all and hit execute again.

It seems to me that his original question is not answered.

What does the erase procedure erase exactly? I was wondering about the same thing also. It can’t be completely empty, otherwise it would not be possible to load anything back in there.

Is it correct that the erase procedure erases TinyBooter and Chipworkx firmware?
In what memory area is the c# (CLR) code stored?

More questions than answers I’m affraid…

Is there some info available about the diffrent types of memory / storage on a Chipworkx?

I think it erases the entire NAND but I am not sure. This is meant to erase to you can load fresh firmware so it is possible that it only erases few sectors.

What exactly are you trying to do?

I’m not trying to do anything, I just want to understand what I’m working with.

When erasing a chipworkx module, it says “Erasing all NOR flash” in the display.
After this, it says “Device is now 100% blank, you need to download TinyBooter”.

However, there must be some software still be running in there, otherwise it should not be possible to install TinyBooter, right?

There is always the sam-ba interface on the CPU, you cannot erase that because it’s in ROM. That’s why you can’t brick the device (unless something fails physically).

I think the 3-button + 3xup only erases the dataflash area… it is enough to make the module go into sam-ba mode because it cannot find the magic code it needs to indentify something as a bootloader. Unless of course if you insert a FAT16 formatted SD card with not more than 2G that contains a boot.bin file (the CPU would still try to execute that).

There is a detailed explanation of the boot process in the data sheet, which is linked in the “LCD ENABLE PIN” topic (actually it’s the wrong datasheet but it’s still good enough).