When we use FatFS, I find that we normally use:
esp_vfs_fat_spiflash_mount
This provides an excellent convenience for building a FAT file system that is accessible via Posix APIs on an ESP-IDF partition that leverages wear leveling. Excellent.
However I believe it has a draw back ... and that is we can't (by any known/easy recipe) create a pre-built FAT image that can be brought into flash memory. For example, if I wanted to use a file system that is read-only (eg. a Web Server) then I don't know of a recipe that will allow me to build my image in Linux and flash it into storage for immediate "use" as a read-only file system.
If I am understanding another part of the story, we can bypass wear leveling and go "straight" to flash storage using the recipe:
* esp_vfs_fat_register
* ff_diskio_register
* f_mount
However, I am not finding any samples that would appear to use this technique.
My question thus comes in a couple of parts:
1. Is there a recipe we can use to build the content of a file system and then write that to flash for immediate use?
2. Is there a sample for using the lower-level FatFS APIs in an ESP32 environment that would apparently not leverage wear leveling and hence (maybe) provide the ability to create external images that could be written to flash for immediate use?
Using FatFS without wear leveling
Using FatFS without wear leveling
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Re: Using FatFS without wear leveling
Have you found a way to solve this problem?
Thanks a lot
Thanks a lot
Who is online
Users browsing this forum: Baidu [Spider], Bing [Bot], ESP_bignacio, Majestic-12 [Bot], MicroController and 131 guests