NetBurner 3.5.6
PDF Version |
This program illustrates basic file system operations for RAM drives:
When the program executes it will display program status information through the debug serial port.
This example is similar to the EFFS-BASIC example, but uses a RAM drive for the file system. The RAM drive configuration is located in the 'ramdrvMcf.cpp' source file.
To build any of the EFFS- examples to use the RAM drive, add the 'ramdrvMcf.cpp' file to the build list and modify 'cardType.h' to define USE_RAM instead of USE_MMC and set the EXT_FLASH_DRV_NUM to the correct RAM drive number.
The RAM drive supports 12, 16 and 32 bit file systems. The most commonly used size is 12-bit, which supports drive sizes from 50k up to 2.8MB. If you change the FAT size, you must make the corresponding change in the function: int fstat = f_format(RAM_DRV_NUM, F_FAT12_MEDIA);
To change the RAM drive file size, edit ramdrv_mcf.cpp.
Minumum RAM drive file system sizes: FAT12: 50KB (most commonly used) FAT16: 2.8MB FAT32: 32MB