ci: Add firmware with filesystem image to artifacts
This commit is contained in:
@@ -18,3 +18,8 @@ jobs:
|
||||
with:
|
||||
name: firmware-RPi-Pico-W
|
||||
path: software/lib/micropython/ports/rp2/build-TONBERRY_RPI_PICO_W/firmware.uf2
|
||||
- name: Upload firmware w/ filesystem
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: firmware-RPi-Pico-W-with-fs
|
||||
path: software/lib/micropython/ports/rp2/build-TONBERRY_RPI_PICO_W/firmware-filesystem.uf2
|
||||
|
||||
3
.gitmodules
vendored
3
.gitmodules
vendored
@@ -7,3 +7,6 @@
|
||||
[submodule "software/lib/microdot"]
|
||||
path = software/lib/microdot
|
||||
url = ../microdot.git
|
||||
[submodule "software/tools/mklittlefs"]
|
||||
path = software/tools/mklittlefs
|
||||
url = https://github.com/earlephilhower/mklittlefs.git
|
||||
|
||||
@@ -11,4 +11,25 @@ set -eu
|
||||
USER_C_MODULES="$TOPDIR"/src/micropython.cmake -j "$(nproc)"
|
||||
)
|
||||
|
||||
echo "Output in lib/micropython/ports/rp2/build-TONBERRY_RPI_PICO_W/firmware.uf2"
|
||||
( cd tools/mklittlefs
|
||||
make -j "$(nproc)"
|
||||
)
|
||||
|
||||
PICOTOOL=picotool
|
||||
if ! command -v $PICOTOOL >/dev/null 2>&1; then
|
||||
echo "system picotool not found, checking SDK build dir"
|
||||
PICOTOOL=lib/micropython/ports/rp2/build-TONBERRY_RPI_PICO_W/_deps/picotool-build/picotool
|
||||
if ! command -v $PICOTOOL >/dev/null 2>&1; then
|
||||
echo "No picotool found, exiting"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
BUILDDIR=lib/micropython/ports/rp2/build-TONBERRY_RPI_PICO_W/
|
||||
tools/mklittlefs/mklittlefs -p 256 -s 868352 -c src/ $BUILDDIR/filesystem.bin
|
||||
truncate -s 2M $BUILDDIR/firmware-filesystem.bin
|
||||
dd if=$BUILDDIR/firmware.bin of=$BUILDDIR/firmware-filesystem.bin bs=1k
|
||||
dd if=$BUILDDIR/filesystem.bin of=$BUILDDIR/firmware-filesystem.bin bs=1k seek=1200
|
||||
$PICOTOOL uf2 convert $BUILDDIR/firmware-filesystem.bin $BUILDDIR/firmware-filesystem.uf2
|
||||
|
||||
echo "Output in $BUILDDIR/firmware.uf2"
|
||||
echo "Image with filesystem in $BUILDDIR/firmware-filesystem.uf2"
|
||||
|
||||
1
software/tools/mklittlefs
Submodule
1
software/tools/mklittlefs
Submodule
Submodule software/tools/mklittlefs added at db0513ade5
@@ -5,3 +5,4 @@ set -eu
|
||||
git submodule update --init lib
|
||||
git -C lib/micropython submodule update --init lib/pico-sdk lib/mbedtls lib/micropython-lib lib/tinyusb lib/btstack lib/cyw43-driver lib/lwip
|
||||
git -C lib/micropython/lib/pico-sdk submodule update --init lib
|
||||
git submodule update --init --recursive tools/mklittlefs
|
||||
|
||||
Reference in New Issue
Block a user