Skip to main content
lakshmikantha85
Visitor II
February 7, 2011
Question

dynamic memory allocation of flash memory

  • February 7, 2011
  • 5 replies
  • 818 views
Posted on February 07, 2011 at 17:01

dynamic memory allocation of flash memory

    This topic has been closed for replies.

    5 replies

    ColdWeather
    Senior
    May 17, 2011
    Posted on May 17, 2011 at 14:24

    What about a file system? If you got KEIL, look at FlashFS (

    http://www.keil.com/support/man/docs/rlarm/rlarm_fs_flashfs.htm

    ). Or try some Open Source file system like ChaNFS...

    Tesla DeLorean
    Guru
    May 17, 2011
    Posted on May 17, 2011 at 14:24

    You can't ''free'' memory, you'd need to leave a 16-bit tag as 0xFFFF so you could mark it as unused (write it to something else later). To recover flash memory, you have to erase the whole page (1K or 2K depending on part). You can however write incrementally. Once you fill a page or pages, you can erase and perform garbage collection.

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    trevor23
    Associate III
    May 17, 2011
    Posted on May 17, 2011 at 14:24

    Simple unless you have to cater for power interruption (or reset) while writing without corrupting the file system

    Andrew Neil
    Super User
    May 17, 2011
    Posted on May 17, 2011 at 14:24

    ''What about a file system?''

     

    Yes, it does sound rather like a simple file system!

     

    Wouldn't need all the complexities of hierarchical directories - just a single, ''root'' level.

    Like early MS-DOS...?
    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
    ColdWeather
    Senior
    May 17, 2011
    Posted on May 17, 2011 at 14:24

    Any write operation to any data storage is critical regardless whether done by own code or by verified file system.