Skip to content

Commit

Permalink
generate firmware for PICO with UART and file system support
Browse files Browse the repository at this point in the history
  • Loading branch information
v923z committed Aug 19, 2023
1 parent ba9167b commit 857e506
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scripts/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ upython_hash=`cd micropython; git describe --abbrev=8 --always; cd ..`
# the cross-compiler is required for each build, so we might as well get it over with
make ${MAKEOPTS} -C micropython/mpy-cross

# chose a delimiter that is not probable to turn up in the description of the file
# choose a delimiter that is not probable to turn up in the description of the file
write_platforms_list() {
if [ -f "platforms.md" ]; then
echo $1"| "$1-$upython_hash-$ulab_hash$ext"| " $2 >> ./platforms.list
Expand Down
2 changes: 1 addition & 1 deletion scripts/rp2/pico.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# This file is part of the micropython-builder project,
# https://github.com/v923z/micropython-builder
# The MIT License (MIT)
# Copyright (c) 2022 Zoltán Vörös
# Copyright (c) 2022-2023 Zoltán Vörös

source ./scripts/rp2/rp2.sh

Expand Down
10 changes: 10 additions & 0 deletions scripts/rp2/pico_uart_vfat.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

# This file is part of the micropython-builder project,
# https://github.com/v923z/micropython-builder
# The MIT License (MIT)
# Copyright (c) 2023 Zoltán Vörös

source ./scripts/rp2/rp2.sh

build_rp2_uart_vfat "PICO"
8 changes: 7 additions & 1 deletion scripts/rp2/rp2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# This file is part of the micropython-builder project,
# https://github.com/v923z/micropython-builder
# The MIT License (MIT)
# Copyright (c) 2022 Zoltán Vörös
# Copyright (c) 2022-2023 Zoltán Vörös

source ./scripts/init.sh

Expand All @@ -12,3 +12,9 @@ build_rp2() {
copy_files rp2/build-$1/firmware.uf2 $1
clean_up rp2 build-$1
}

build_rp2_uart_vfat() {
make ${MAKEOPTS} -C micropython/ports/rp2 BOARD=$1 USER_C_MODULES=../../../ulab/code/micropython.cmake CFLAGS_EXTRA=-DULAB_HASH=$ulab_hash CFLAGS_EXTRA=-DMICROPY_HW_ENABLE_UART_REPL=1 CFLAGS_EXTRA=-DMICROPY_HW_USB_MSC=1
copy_files rp2/build-$1/firmware.uf2 "$1"_UART_VFAT
clean_up rp2 build-$1
}

0 comments on commit 857e506

Please sign in to comment.