Erase parts of the flash of a watch connected through a development kit: regions of the board’s flash layout, by name, or offset ranges in it.
Warning
Erasing FILESYSTEM wipes the pairings, apps and settings stored on the
watch.
pbl erase --region FILESYSTEM --region SHARED_PRF_STORAGE
The regions are the partitions of the build: those of its devicetree, or of
the include/pbl/board/partitions_*.h header of the board’s layout.
--region NAME:SIZE erases only the first SIZE bytes of a
region, and --range OFFSET:SIZE any range; both can be repeated. Ranges
start at offset 0 of the flash, and must be aligned to its erase size
(4 KiB).
pbl erase [-h] [-b DIR] [--dry-run] [--lab FILE] [--watch NAME]
[--wait [SECONDS]] [--region NAME[:SIZE]] [--range OFFSET:SIZE]
[-r {native,nrfutil,openocd,phone,probe-rs,qemu,sftool,wasm}]
[--tty TTY] [--probe VID:PID[:SERIAL]] [--keep-flash-image]
[--decoration NAME] [--sunlight] [--bt-hci CHARDEV]
[--http-port HTTP_PORT] [--no-browser] [--via {adb,cloud,ip}]
[--address ADDRESS] [--adb-serial ADB_SERIAL]
--region NAME[:SIZE]Erase a flash region, or only its first SIZE bytes (repeatable)
--range OFFSET:SIZEErase SIZE bytes from flash OFFSET (repeatable)
-r, --runner {native,nrfutil,openocd,phone,probe-rs,qemu,sftool,wasm}Override the board’s runner
--tty TTYSerial port for the sftool and probe-rs runners (default: the lab’s)
--probe VID:PID[:SERIAL]Debug probe for the probe-rs runner (default: the lab’s)
--keep-flash-imageKeep the emulator’s SPI flash image, and the apps and data in it, instead of rebuilding it
--decoration NAMESDL decoration the emulator draws around the screen, or ‘none’ (default: the board’s first)
--sunlightShow the colors as a watch’s panel does in sunlight
--bt-hci CHARDEVH4 Bluetooth controller for builds with CONFIG_BT_HCI_UART, e.g. the serial port /dev/cu.usbmodem1101
--http-port HTTP_PORTPort the wasm runner serves the page on (default: 8000)
--no-browserDo not open the page the wasm runner serves in a browser
--via {adb,cloud,ip}How the phone runner reaches the phone’s Developer Connection: adb (Android, the default), cloud (signed in with ‘pebble login’) or ip (implied by –address)
--address ADDRESSPhone address (Developer Connection) for the phone runner
--adb-serial ADB_SERIALSerial of the Android phone for the phone runner, when adb sees several
Generated from PebbleOS 7753e801d. This page is maintained in the pebbleos repository: docs/pbl/erase.md.