Skip to content

Commit fa393fe

Browse files
committed
esp32/README: Update README to describe auto filesystem sizing.
Signed-off-by: Damien George <damien@micropython.org>
1 parent 6201e77 commit fa393fe

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

ports/esp32/README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,30 @@ import machine
221221
antenna = machine.Pin(16, machine.Pin.OUT, value=0)
222222
```
223223

224+
Partition table and filesystem size
225+
-----------------------------------
226+
227+
ESP32 firmware contains a bootloader, partition table and main application
228+
firmware, which are all stored in (external) SPI flash. The user filesystem
229+
is also stored in the same SPI flash. By default, MicroPython does not have
230+
a fixed entry in the ESP32 partition table for the filesystem. Instead it
231+
will automatically determine the size of the SPI flash upon boot, and then --
232+
so long as there is no existing partition called "vfs" or "ffat" -- it will
233+
create a partition for the filesystem called "vfs" which takes all of the
234+
remaining flash between the end of the last defined partition up until the
235+
end of flash.
236+
237+
This means that firmware built for, say, a 4MiB flash will work on any
238+
device that has at least 4MiB flash. The user "vfs" filesystem will then
239+
take up as much space as possible.
240+
241+
This auto-detection behaviour can be overridden: if the ESP32 partition
242+
table does contain an entry called "vfs" or "ffat" then these are used for
243+
the user filesystem and no automatic "vfs" partition is added. This is
244+
useful in cases where only the MicroPython ESP32 application is flashed to
245+
the device (and not the bootloader or partition table), eg when deploying
246+
.uf2 files.
247+
224248
Defining a custom ESP32 board
225249
-----------------------------
226250

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy