summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn Ruben Bakke <glennbakke@gmail.com>2020-07-23 12:29:10 +0200
committerDamien George <damien@micropython.org>2021-08-08 23:09:26 +1000
commitb40dfa961dcd9c3504f742c212248444b68413b3 (patch)
tree57e398adc8263a7575fdb4b5f2abf548fe47ea65
parent85cad502660e8d1359f175402aaea98695b3521f (diff)
nrf/README: Update README.md to reflect internal file systems.
This documents parameters that can be passed to make to enable a specific file system to included in the build. Also, document the Makefile override parameter "FS_SIZE" that can be used to tune the size of the flash region to use as internal flash file system.
-rw-r--r--ports/nrf/README.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/ports/nrf/README.md b/ports/nrf/README.md
index 0341cd81c..a4509cc6e 100644
--- a/ports/nrf/README.md
+++ b/ports/nrf/README.md
@@ -117,6 +117,34 @@ For example:
make BOARD=pca10040 MICROPY_VFS_FAT=1
+## Enable MICROPY_VFS_LFS1 or MICROPY_VFS_LFS2
+
+In order to enable `littlefs` as device flash filesystem, `MICROPY_VFS_LFS1`
+or `MICROPY_VFS_LFS2` can be set. This will be in addition of setting
+`MICROPY_VFS` in mpconfigport.h or mpconfigboard.h.
+
+For example:
+
+ make BOARD=pca10056 MICROPY_VFS_LFS2=1
+
+## Set file system size
+
+The size of the file system on the internal flash is configured by the linker
+script parameter `_fs_size`. This can either be overriden by the linker script
+or dynamically through the makefile. By seting a value to the `FS_SIZE`.
+The number will be passed directly to the linker scripts in order to calculate
+the start and end of the file system. Note that the parameter value must be in
+linker script syntax as it is passed directly.
+
+For example, if we want to override the default file system size set by the
+linker scripts to use 256K:
+
+ make BOARD=pca10056 MICROPY_VFS_LFS2=1 FS_SIZE=256K
+
+Also note that changing this size between builds might cause loss of files
+present from a previous firmware as it will format the file system due to a new
+location.
+
## Target Boards and Make Flags
Target Board (BOARD) | Bluetooth Stack (SD) | Bluetooth Support | Bootloader | Default Flash Util