DfFat for dataflash and others

Hi, would be possible to create a "mini" version called ie. DfFat - a simple filesystem for dataflash memories (ie. AT45DB..., the driver is available) or other types of similar devices? With few commands like fopen, fclose, fremove, fwrite, fread.. ?? p.

(ie. AT45DB..., the driver is available)

There is an Arduino driver for the device?

Yes it would be possible. I have played with the idea for several years. I bought some 32 Mbit Dataflash parts but never pursued the idea.

To get any advantage over an SD you need a special filesystem. The problem is rewrite takes forever on Dataflash and there is no wear-leveling.

You need something like JFFS2, LogFS, UBIFS, or YAFFS. I think JFFS2 is best for devices up to 64MB.

http://en.wikipedia.org/wiki/JFFS2

@PaulS - yes, here you are - http://arduino.cc/playground/Code/Dataflash @fat16lib - those at45db081d and higher have got 2x 512(528)bytes large internal SRAM buffers, for ping-pong like operation, so you write full speed a block into buffer1 and then you write it to df with one command, and while it writes the block into the df you can feed the buffer2, etc. So it might be faster than the sdcards are, I guess.. And FRAM and MRAM - you can write full SPI speed random, no latencies, unlimited endurance.. PS: If I were you I take SdFat and connect the low level routines from above dataflash driver to it, somehow.. Then we may test :) The FRAM and MRAM - it works straight like serial SRAM, no special drivers required..

pito,

You need to read the datasheet. Many people have been tricked by the "ping-pong" thing.

Here are some times (typical and max) Page erase and programming time (512-/528-bytes) 17 40 ms Page programming time (512/528 bytes) 3 6 ms Page erase time (512/528 bytes) 15 35 ms Block erase time (4,096/4,224 bytes) 45 100 ms Sector erase time (131,072/135,168 bytes) 1.6 5 s

So you can ping-pong write a block at typical 17 ms for a block or about 30 KB/sec. Programing time is horrible. 3 ms typical 6 ms max.

If you are streaming to the part you face this:

The erase and the programming of the page are internally self-timed, and should take place in a maximum time of tEP. During this time, the status register and the RDY/BUSY pin will indicate that the part is busy.

So the ping-pong thing does little good. Or as some people say Dataflash is slow as molasses.

Most MTD flash memory devices have a real downside when used for file systems. That's why all popular flash devices for file systems, like SD cards and SSDs, have a block erase/wear controller.

I have not pursued F-RAM since the parts are low density so a file system makes less sense. Dataflash at 32 Mbit is about the minimum density suitable for a file system.

Unless we can write a 512bytes large block in 512usecs its bad :roll_eyes:

Here I've found something related to the dataflash drivers - for somebody who does not chase the speed http://blockos.github.com/arduino-dataflash/doxygen/html/modules.html

MRAM - I've got a 4Mbit part - a good size for experiments.. p.