Merge pull request #55 from cjkas/build/same-fs-partition

build: give the debug build the release file system size
This commit is contained in:
cjkas 2026-10-17 23:11:59 +02:00 • committed by GitHub
commit 67da75fcf4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 2 deletions

View file

@ -185,6 +185,8 @@ Code moved unchanged; only files and names changed.
The subscribe and unsubscribe lists, which repeated `groups/+/direction/set`, became the one `MQTT_COMMAND_TOPICS` list, and a native test checks that the parser takes every topic in it. Flash: `esp32devdbg` 1,536,533 → 1,539,645 bytes (+3.1 KB, since the routes are a second file that uses ArduinoJson, as SOMFY_SPLIT_PLAN.md warned), `esp32dev` 1,393,449 → 1,391,113 bytes (−2.3 KB, where `-Os` inlines less). The subscribe and unsubscribe lists, which repeated `groups/+/direction/set`, became the one `MQTT_COMMAND_TOPICS` list, and a native test checks that the parser takes every topic in it. Flash: `esp32devdbg` 1,536,533 → 1,539,645 bytes (+3.1 KB, since the routes are a second file that uses ArduinoJson, as SOMFY_SPLIT_PLAN.md warned), `esp32dev` 1,393,449 → 1,391,113 bytes (−2.3 KB, where `-Os` inlines less).
### Step 0 on a device ### Step 0 on a device
**No longer needed:** `esp32_huge_app.csv` now has the release file system (`0xE0000` at `0x310000`) and puts the coredump in the 64 KB that was unused at the end, so the debug and release builds share one data layout and either can be flashed over the other. A device formatted at `0xD0000` grows to `0xE0000` on its next mount, which LittleFS can do. What follows was the procedure while the debug table had the smaller file system.
NVS stays at `0x9000`, so the rolling codes survive. The file system partition shrinks from `0xE0000` to `0xD0000`, and the existing LittleFS won't mount, because `LittleFS.begin()` doesn't format. So: NVS stays at `0x9000`, so the rolling codes survive. The file system partition shrinks from `0xE0000` to `0xD0000`, and the existing LittleFS won't mount, because `LittleFS.begin()` doesn't format. So:
1. Take a backup through `/backup`. 1. Take a backup through `/backup`.
2. Flash the partition table, firmware and file system over USB: `pio run -e esp32devdbg -t upload -t uploadfs`. 2. Flash the partition table, firmware and file system over USB: `pio run -e esp32devdbg -t upload -t uploadfs`.

View file

@ -2,5 +2,5 @@
nvs, data, nvs, 0x9000, 0x5000, nvs, data, nvs, 0x9000, 0x5000,
otadata, data, ota, 0xE000, 0x2000, otadata, data, ota, 0xE000, 0x2000,
app0, app, factory, 0x10000, 0x300000, app0, app, factory, 0x10000, 0x300000,
spiffs, data, spiffs, 0x310000, 0xD0000, spiffs, data, spiffs, 0x310000, 0xE0000,
coredump, data, coredump, 0x3E0000, 0x10000, coredump, data, coredump, 0x3F0000, 0x10000,
1 # Name, Type, SubType, Offset, Size
2 nvs, data, nvs, 0x9000, 0x5000,
3 otadata, data, ota, 0xE000, 0x2000,
4 app0, app, factory, 0x10000, 0x300000,
5 spiffs, data, spiffs, 0x310000, 0xD0000, spiffs, data, spiffs, 0x310000, 0xE0000,
6 coredump, data, coredump, 0x3E0000, 0x10000, coredump, data, coredump, 0x3F0000, 0x10000,