Skip to the text
KDOS
Menu
kdos.dev KDOS from Scratch KDOS 0.2 · 4dd4a10 · 2026-11-30 Contents Index

161.26. picotool-2.3.1

RP2040 and RP2350 UF2 inspection and USB loading

2.3.1-1 · BSD-3-Clause · 3.3 SBU · 3.4 MiB, 10 files · 41_system, 485 of 1047 · ports/core/embedded/picotool

Homepage: https://github.com/raspberrypi/picotool

Why it is in KDOS. The comment above it in script/phases/41_system/packages.d/embedded.txt:

RP2040/RP2350 UF2 inspection and USB loading — a host program that reads and writes those images, needing the SDK's headers and no cross toolchain.

Depends on: cmake, libusb, pkgconf, gcc-arm-none-eabi, binutils-arm-none-eabi, picolibc-arm-none-eabi, libstdcxx-arm-none-eabi.

Required by: no port names it.

Sources: mbedtls-3.6.7.tar.bz2 (5.2 MiB), pico-sdk-2.3.1.tar.gz (2.6 MiB), picotool-2.3.1.tar.gz (1.3 MiB). Every step kpkg takes applies to this port.

Install: script/chroot/exec.sh bash -c 'source script/phases/41_system/phase.env && kpkg install picotool'

build.sh:

rm -f enc_bootloader/enc_bootloader.elf enc_bootloader/enc_bootloader_mbedtls.elf \
	xip_ram_perms/xip_ram_perms.elf picoboot_flash_id/flash_id.bin
export PICO_TOOLCHAIN_PATH=/usr PICO_MBEDTLS_PATH="$SRC_ROOT/mbedtls-$_mbedtls"
mkdir -p build && cd build
cmake .. -DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
	-DCMAKE_INSTALL_PREFIX=/usr \
	-DPICOTOOL_NO_LIBUSB=OFF \
	-DUSE_PRECOMPILED=OFF \
	-DPICO_SDK_PATH="$SRC_ROOT/pico-sdk-$version"
make
DESTDIR=$PKG cmake --install .
test -n "$(find "$PKG" -name enc_bootloader_mbedtls.elf)"

Programs: picotool.

Directories: /usr/lib/cmake/picotool, /usr/share/licenses/picotool, /usr/share/picotool.