This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Flash File system on LPC2129

Hello everyone,

I'm trying to get Flash File System(FFS) to get working on a LPC2129. The RAM is only 16kB and since minimum requirement for FFS-RAM is 16kB only, i can't get this to work.

On the other hand i have the internal flash 256kB, which i've tried to use in different configuration... But i can't seem to get it to work. Can anyone please give me a little hand to get the internal flash to work with FFS.

I've included the LPC_128 folder into my project.

Using file_ex1 also with no success.

Please point out if i'm assuming anything wrong.

To add:
1. if i try to use FFS-RAM, it shows it has made file, but i can't read it back
2. If i try to use FFS-Internal Flash, the program stops responding when accessing/writing files.

Thanks and regards,

Akshat

  • Hallo Akshat Bishit,

    it is not possible to use the LPC21xx internal FLASH for FFS. Please see FFS user manual www.keil.com/.../rlarm_fs_usingflash_internal.htm
    and also LPC2129 user manual chapter 1.7 Flash content protection mechanism.

    Best Regards,
    Martin Guenther

  • Sir,

    I could not locate the flash content protection feature in the user-manual of LPC2129. More so,the RL-ARM page states that feature to be only in LPC 213x and 214x controllers.

    I still feel somewhere i'm going wrong in configuring the flash memory in FFS.

    Thanks and regards,

    Akshat

  • UM10114 rev 02: LPC21xx/22xx User Manual

    Page 316:
    The LPC21xx/LPC22xx is equipped with the Error Correction Code (ECC) capable flash memory.

    Since this device has ECC Flash it is not possible to use FFS.

  • thank you sir,

    I didn't find that in the user-manual listed on the specifications page of LPC2129 @ nxp.com

    But is in the manual you mentioned.

    Thank you for the input.

    Could you suggest a way to use IAP for FFS in this micro-controller or has that got to be a self-made solution?

    Regards,

    Akshat

  • What do you mean by "IAP for FFS"?

    IAP is one thing. A flash file system something else.

    Sectors with ECC can only be written once before being erased, while most flash file systems normally writes several times to the same sector before erasing it.

    ECC doesn't block the availability of IAP. It just requires that if you store a log or any other growable structure in a flash sector, then you must always copy the data out of the sector, erase the sector and then write back the new data whenever you want to grow the log. Without ECC, it is possible to just continue to write the new data at the end of the previous log. Or for a flash file system to write a couple of bits to signal that sector X has been replaced by new data at a different location.

  • OK, i get the point. I was wondering why couldn't the IAP functions be used to implement the FFS. But then re-write would become a problem.

    Right!

    Thanks a lot.

    Akshat