Change size of FFS drive (MQX 4.0.1, TWR-K70)

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Change size of FFS drive (MQX 4.0.1, TWR-K70)

Jump to solution
4,091 Views
friederschrempf
Contributor IV

I'm using the FFS library with the example project (NAND Flash File System patch for Freescale MQX™ RTOS 4.0.0). After running the format command from the shell I always get 10 723 328 bytes free disk space.

I want to enlarge the drive to cover e.g. 100M of NANDFLASH. I tried modifiying NANDFLASH_1ST_DATA_DRIVE_SIZE_IN_BLOCK but without effect.

Has anyone got a hint for me, please? Thank you!

1 Solution
2,450 Views
DavidS
NXP Employee
NXP Employee

Hi Frieder,

I opened the nandflash_wl.ffs.h header in the ffs_twrk70f120m project and changed the define as follows:

#define NANDFLASH_1ST_DATA_DRIVE_SIZE_IN_BLOCK 200 //DES was 90

Recompile the ffs, then recompile the mfs_nandflash_twrk70f120m example project and it did increase the disk space.

ScreenHunter_23 Jun. 27 13.26.gif

Note that the default 90 size gave a 10.7MB disk and a 200 size gave a 251MB size.

So the example we have is generating (or partitioning) a small disk on the NAND flash and not making it one big disk.

The specific NAND device information is in the bsp_twrk70f120m MT29F2G16.c file.

When I changed the block to 1937 (2048-110-1) I got a big disk.

ScreenHunter_24 Jun. 27 13.35.gif

Regards,

David

View solution in original post

0 Kudos
Reply
23 Replies
2,451 Views
DavidS
NXP Employee
NXP Employee

Hi Frieder,

I opened the nandflash_wl.ffs.h header in the ffs_twrk70f120m project and changed the define as follows:

#define NANDFLASH_1ST_DATA_DRIVE_SIZE_IN_BLOCK 200 //DES was 90

Recompile the ffs, then recompile the mfs_nandflash_twrk70f120m example project and it did increase the disk space.

ScreenHunter_23 Jun. 27 13.26.gif

Note that the default 90 size gave a 10.7MB disk and a 200 size gave a 251MB size.

So the example we have is generating (or partitioning) a small disk on the NAND flash and not making it one big disk.

The specific NAND device information is in the bsp_twrk70f120m MT29F2G16.c file.

When I changed the block to 1937 (2048-110-1) I got a big disk.

ScreenHunter_24 Jun. 27 13.35.gif

Regards,

David

0 Kudos
Reply
245 Views
okaner
Contributor III

Hi David,

    I installed mqx 4.0.2 and new ffs. I have done same steps but now I get smaller disk size. Do you have any idea. Thank you. TWRK60f120m. I was successful on mqx 4.0.1.

nandflash_wl_ffs.h

#define NANDFLASH_1ST_DATA_DRIVE_SIZE_IN_BLOCK 1937

#define NANDFLASH_1ST_DATA_DRIVE_START_BLOCK 110

Formating...                                                                 
Done. Volume name is                                                         
Free disk space: 126212096 bytes

Okan ERCAN

0 Kudos
Reply
245 Views
friederschrempf
Contributor IV

Thank you for your detailed instructions!

I have tried this before. Now I had a closer look at the recompiled library and found out, that the nandflash_wl_ffs.h file in the library directory was somehow not replaced by the new one. I deleted it manually. Rebuild again and then it worked.

0 Kudos
Reply