Commit 4930853e authored by Cellie's avatar Cellie Committed by Me No Dev

Add support for ffat on 4MB ESP32 Dev Module and mhetesp32minikit board. (#2588)

* Update boards.txt

Add menu items for ffat on mhetesp32minikit board.

* Add partition table.

* Added ffat partition for 4MB ESP32 Dev Module.

* Added comment about partitioning schemes.
parent 8e8c5035
......@@ -64,8 +64,10 @@ esp32.menu.PSRAM.disabled.build.defines=
esp32.menu.PSRAM.enabled=Enabled
esp32.menu.PSRAM.enabled.build.defines=-DBOARD_HAS_PSRAM -mfix-esp32-psram-cache-issue
esp32.menu.PartitionScheme.default=Default
esp32.menu.PartitionScheme.default=Default with spiffs (4MB FLASH)
esp32.menu.PartitionScheme.default.build.partitions=default
esp32.menu.PartitionScheme.defaultffat=Default with ffat (4MB FLASH)
esp32.menu.PartitionScheme.defaultffat.build.partitions=default_ffat
esp32.menu.PartitionScheme.minimal=Minimal (2MB FLASH)
esp32.menu.PartitionScheme.minimal.build.partitions=minimal
esp32.menu.PartitionScheme.no_ota=No OTA (Large APP)
......@@ -1555,8 +1557,10 @@ mhetesp32minikit.menu.FlashFreq.80.build.flash_freq=80m
mhetesp32minikit.menu.FlashFreq.40=40MHz
mhetesp32minikit.menu.FlashFreq.40.build.flash_freq=40m
mhetesp32minikit.menu.PartitionScheme.default=Default
mhetesp32minikit.menu.PartitionScheme.default=Default with spiffs
mhetesp32minikit.menu.PartitionScheme.default.build.partitions=default
mhetesp32minikit.menu.PartitionScheme.defaultffat=Default with ffat
mhetesp32minikit.menu.PartitionScheme.defaultffat.build.partitions=default_ffat
mhetesp32minikit.menu.PartitionScheme.no_ota=No OTA (Large APP)
mhetesp32minikit.menu.PartitionScheme.no_ota.build.partitions=no_ota
mhetesp32minikit.menu.PartitionScheme.no_ota.upload.maximum_size=2097152
......
#include "FS.h"
#include "FFat.h"
// This file should be compiled with 'Partition Scheme' (in Tools menu)
// set to 'Default with ffat' if you have a 4MB ESP32 dev module or
// set to '16M Fat' if you have a 16MB ESP32 dev module.
// You only need to format FFat the first time you run a test
#define FORMAT_FFAT true
......@@ -160,7 +164,7 @@ void setup(){
Serial.println("FFat Mount Failed");
return;
}
Serial.printf("Total space: %10lu\n", FFat.totalBytes());
Serial.printf("Free space: %10lu\n", FFat.freeBytes());
listDir(FFat, "/", 0);
......
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x5000,
otadata, data, ota, 0xe000, 0x2000,
app0, app, ota_0, 0x10000, 0x140000,
app1, app, ota_1, 0x150000,0x140000,
eeprom, data, 0x99, 0x290000,0x1000,
ffat, data, fat, 0x291000,0x16F000,
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment