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

File System programming

Hi,everyone

I am working on lpc1788 with nand flash interface, In my application i have face the problem related to file system ,My nand flash data gets corrupted, no data is available in nand flash.
In my application, i am continuously open file , data read from file , sometimes appending data , and sometimes erase the data (not completely only last time appended data apprx.20 bytes) and again append the data ,and close the file,such operation i am doing 100 times,

In my application,after gathering all data i saved it to another file ,delete that file ,and for next RUN part again creating same name file ,doing the same operation for 100 times.

And i am doing such operation for 10 file ,data writing and appending operation done by one by one file .And also after any single file operations i have taken care for file close.

i want to know whether there is any limitation for file opening,writing, closing related .

someone please help me out,or give me some suggestion on this ,i am not experty on RTOS and file system.why my nand flash gets corrupted, what are the possibilities for nand flash corruption.

Thanks.

  • Thanks ,for reply.

    Have u seen my one thread which i have posted one 2day back with title:
    File system programming.

    Do you help me on that.

    My nand flash data gets all blank(all directories are lost) after power on , some times if any of my one file stored in nand flash directory gets corrupted.

    heres is my all directories before data get corrupted:

    File System Directory...
    FILE.TXT 27 01.01.2011 12:00
    SETTING <DIR> 01.01.2011 12:00
    Default_setup <DIR> 01.01.2011 12:00
    Method_setup <DIR> 01.01.2011 12:00
    Report_template <DIR> 01.01.2011 12:00
    Calibration_Results <DIR> 01.01.2011 12:00
    Verification_Results <DIR> 01.01.2011 12:00
    User_Security 01.01.2011 12:00
    Group_Security <DIR> 01.01.2011 12:00
    Delete_group <DIR> 01.01.2011 12:00
    LIST <DIR> 01.01.2011 12:00
    Cal_result <DIR> 01.01.2011 12:00
    Product_setup <DIR> 01.01.2011 12:00
    EHT5P_RESULTS <DIR> 01.01.2011 12:00
    Test_result <DIR> 01.01.2011 12:00 1 File(s) 27 bytes 14 Dir(s) 503.037.952 bytes free.

    File System Directory...
    . <DIR> 01.01.2011 12:00
    .. <DIR> 01.01.2011 12:00
    PRODUCT.TXT 328 01.01.2011 12:00
    VXGCH.TXT 328 01.01.2011 12:00
    VGCU.TXT 328 01.01.2011 12:00
    VCH.TXT 328 01.01.2011 12:00
    GHNJ.TXT 328 01.01.2011 12:00
    VVBH.TXT 328 01.01.2011 12:00
    GGH.TXT 328 01.01.2011 12:00
    BBN.TXT 328 01.01.2011 12:00
    CCVVGVJ.TXT 328 01.01.2011 12:00
    BBNJ.TXT 328 01.01.2011 12:00 10 File(s) 3.280 bytes 2 Dir(s) 503.037.952 bytes free.

    File System Directory...
    . <DIR> 01.01.2011 12:00
    .. <DIR> 01.01.2011 12:00
    VID list.txt 11 01.01.2011 12:00
    report template list.txt 28 01.01.2011 12:00
    user list.txt 17 01.01.2011 12:00
    group list.txt 18 01.01.2011 12:00
    CID list.txt 48 01.01.2011 12:00
    product list.txt 65 01.01.2011 12:00
    method list.txt 65 01.01.2011 12:00
    TID list.txt 283 01.01.2011 12:00 8 File(s) 535 bytes 2 Dir(s) 503.037.952 bytes free.

    but,after any of one file system operation gets hanged or anything data file corrupted(internally on driver what is going on i don't know, as i am writing on application code) ,why all files and directory's are not found.

    it gives me no directory's found.

    Please ,Please help on out.or suggest some check.