The rewrite. RPCortex was MicroPython for four versions; this one is C++, and almost everything underneath is different even though the shell is deliberately familiar.
The headline
No interpreter
RPCMark scores around 1.2 million against a v1 device's 5,000–6,000
— roughly 200×. That is not a projection: bench
runs the same workload as tools/bench.py does on v1, same iteration counts,
so the two numbers are the same measurement taken twice.
One image, drag and drop
No firmware to flash and then files to paste on top of it. Hold BOOTSEL, drop a
.uf2, done — and after that the device updates itself over the air.
Packages cannot take the device down
The part with no equivalent in v1 at all. On RP2350 a package runs unprivileged, with the memory protection unit describing exactly five regions it may touch, and every pointer it hands the firmware range-checked against those regions.
| The package… | Costs you |
|---|---|
| Uses a bad pointer | The command. A report names it; the shell carries on. |
| Stops responding entirely | The command. A timer takes the call back. |
| Runs out of its own stack | The command. |
| Asks for something that does not exist | Nothing. The call is refused. |
havoc is a package built to attack
the ABI from inside the sandbox — null pointers, pointers into flash, lengths that
overflow, unterminated strings, handles that were never opened — and all 62 of its
checks have to come back as clean refusals.
New in v2
- Both cores. v1 could not use core 1 at all; MicroPython's heap is not safe across cores. An unpinned task here lives on core 1 about 99% of the time.
- A task manager.
psshows pid, state, core, stack used against allocated, CPU time and where each task was started from.killstops one. On v1 a misbehaving background service could only be found by rebooting. - Crash reporting that survives the crash. A log ring and a black box in memory the reset does not clear, so the next boot says what the last run was doing when it stopped. v1 lost everything on reboot.
- A USB drive.
downloadpresents a real FAT volume, so files move by drag and drop in both directions instead of over the serial line. - Bluetooth. The same chip does both radios. v1 could not reach Classic at all — MicroPython's module is BLE only — so anything that plays audio was out of reach.
- Real background work. v1's
task runentered a foreground scheduler: you got scheduled tasks or an interactive shell, not both. Here the timer is just another task. - Interruptible everything. Ctrl+C stops any command instantly, because the interrupt check and the scheduler yield are the same call.
- PIO, SPI and I2C for packages, which is what makes drivers possible without touching the firmware.
What matches v1
The filesystem commands down to ls's exact columns. Text processing.
Accounts with salted SHA-256, roles and the guided first run. The shell: pipes,
&&, ||, ;, redirection, quoting, history,
thirty aliases. wifi with all its subcommands, ping,
nslookup, ntp. startup, task,
service, watch. The .rps scripting language,
unchanged — scripts carry over as they are.
And the console itself: v1's tagged output, colours and boot banner, checked byte for byte against the original escape sequences.
Boards
| Board | Firmware | Filesystem | Package sandbox |
|---|---|---|---|
| Pico 2 W | 916 KB | 2 MB | yes |
| Pico 2 | 320 KB | 3 MB | yes |
| Pico W | 748 KB | 384 KB | no |
| Pico | 247 KB | 1.25 MB | no |
The RP2040 boards are back. v1.0 had to drop them because the multitasking build did not fit in 264 KB of RAM; without an interpreter it does. They hold 2 MB of flash against the RP2350's 4, so the firmware is built for size there and the filesystem is smaller — with wireless, Bluetooth, TLS and over-the-air updates all still in. What they do not get is the package sandbox: ARMv6-M protection regions are power-of-two sized and aligned to their own size, so the five a package needs cost more RAM than those boards have.
Installing
- Hold BOOTSEL and plug the board into USB.
- Drag the
.uf2for your board onto the drive that appears. Pick it from the Get page. - Open a serial terminal at 115200 baud.
The first boot asks for a root password once. After that,
update handles new releases over the air.
Upgrading from v1
Scripts carry over. The .rps language is the same, and
capture deliberately sees what a pipe would, so lines like
capture n wc -l file behave identically on both.
Packages do not. A v1 .pkg is Python source and there is no
Python in v2. The ones in the repository have been rewritten in C; a package of your own
needs the same treatment. The package guide covers it.
Known limitations
- Fewer packages than v1. Porting the rest is the main distance left to parity — the Packages page lists what is in the v2 index today.
- SD cards are built but unproven. The card driver, a read-only FAT
reader and the
sdcommand are in the RP2350 images, and/sdgoes through the same storage calls flash does. Everything above the wire is host-tested; none of it has been run with a card in the slot. - No ESP32-S3 yet. v1 runs there and continues to. The portable core moves unchanged, but the context switch, storage and network layers do not.
- Cooperative scheduling. A task that never yields cannot be killed from the shell. There is a timer backstop for packages, not for firmware.
- Bluetooth is uneven. An LE scan is confirmed on a Pico 2 W. Classic
inquiry,
bt advertiseand playing audio to a speaker are all written and host-tested, but none has been confirmed against a real device yet.
RPCortex Vela II — v2.0.0 • by dash1101. Issues and PRs welcome. Earlier releases: v1.0 Vela · v0.9.1 Pulsar.