Releases: UKTailwind/micropython
Release list
Pico Computer 3 & 2 v0.14 (test)
Firmware and manual for the Pico Computer 3 and the Pico Computer 2 (RP2350B).
New in v0.14
- The same firmware now runs on the Pico Computer 2 — plug it in and it works out for itself which machine it is on, at start-up, before anything else happens. The test is the DS3231's 32 kHz clock, which only the Pico Computer 3 wires to a pin (GP27), and it is the same test MMBasic makes. Nothing changes for a Pico Computer 3.
- SD card on the Pico Computer 2's own pinout — CS GP29, SCK GP30, MOSI GP31, MISO GP32. Those pins do not line up with either hardware SPI block, so the card is driven by a bit-banged SPI bus ported from MMBasic, at the same clock speeds. Mounting, hot-swap and everything above it behave exactly as on the Pico Computer 3.
- No Wi-Fi/Bluetooth on the Pico Computer 2 — and it is now safe about it. The wireless chip's pins are used for other things on that board (the LED on GP25 and the SD chip select on GP29), so starting the radio there would have taken over a live SD chip select and corrupted the card. The firmware never brings it up, and
network.WLAN(),bluetooth.BLE()andPin("LED")raise a clear error instead.wifi()says there is no radio rather than hanging. - The banner names the board it found — a Pico Computer 2 now greets you with
MicroPython v1.29.0-preview on PICO COMPUTER 2 v0.14 with RP2350B, andos.uname().machineagrees. (sys.implementation._machineis fixed at build time and still names the 3.) - New
boardmodule —board.name(),board.id(),board.has_wifi(),board.led_pin(). On a Pico Computer 2 the LED is ready to use asLED(e.g.LED.toggle()); on a Pico Computer 3 it is stillPin("LED", Pin.OUT). If a Pico Computer 3's RTC has stopped it can be mistaken for a 2 —board.override(board.PICO_COMPUTER_3)then Ctrl-D puts it right. - The clock and everything else are unchanged on both boards — both have the DS3231, so
settime()/gettime()/synctime()work either way; the Pico Computer 2 simply does not route the 32 kHz output. The one exception is the RTC alarm's INT line (ds3231.alarm_pin()), which is GP32 — the SD card's data line on a Pico Computer 2. - PC emulator — the refreshed
pc3emu-linux-x64.tar.gzis at banner v0.14 and includes theboardmodule. Runs on Linux, and on Windows via WSL2 — seeINSTALL-WINDOWS.mdinside the tarball. Needs glibc 2.43 / Ubuntu 26.04+ for the prebuilt binary; on older systems build from source (a few minutes, any distro). - File manager fixes — a program started from
fm()can now be stopped with Ctrl-C, exactly as at the command line (it previously inherited fm's own key handling, where Ctrl-C is the quit key rather than an interrupt, and ran unstoppably; editing the file first happened to work around it). Ctrl-C stops the program and returns you to the panels. Separately,fm()no longer shows every file as 0 bytes on filesystems whose directory listing omits the size — it falls back tostat(). - Manual updated with a "Running on a Pico Computer 2" section (section 2).
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
Pico Computer 3 v0.12 (test)
Firmware and manual for the Pico Computer 3 (RP2350B).
New in v0.12
- SQLite hardened against resets and power loss — a full review of the on-device SQLite engine (
import usqlite) fixed three classes of defect. A soft reset (Ctrl-D) with a database open no longer corrupts the engine (previously the next session could hard-lock on its firstdb.close()); connections and cursors are now fully garbage-collector-safe (a use-after-free onclose(), and dropped connections leaking their memory for the rest of the session);INTEGERcolumns are now true 64-bit in both directions — millisecond timestamps stored from Python no longer overflow on write or silently wrap on read. Filesystem trouble (missing directory, full flash, an SD card pulled mid-query — pulling the card is a supported action) now raises a clean Python error and leaves the engine healthy instead of unwinding through SQLite's internals. And power-fail recovery now actually works: a power cut mid-write leaves a "hot journal" that is detected and rolled back on the next open, where previously a torn database could be served as valid — verified on hardware with physical power pulls during committed batch writes (clean rollback each time). The API is unchanged and existing databases are unaffected. On-device test suite included (tests/sqltest_a..e.py). - USB mouse: high-resolution mice fixed, and any HID mouse now works — mice reporting 12- or 16-bit movement moved erratically: the firmware left the mouse in USB boot mode (plain 8-bit reports) while decoding the full-resolution format the mouse describes, so the two never matched. The mouse is now switched to report mode at connect (as MMBasic does), and the decoder has been generalised to read each mouse's own HID descriptor — any button count, movement resolution, wheel position or report-ID scheme — instead of recognising three fixed layouts. Combo receivers that share the mouse interface with media keys no longer jitter the cursor when those keys are pressed, and a mouse that refuses the mode switch falls back cleanly to 8-bit decoding.
- PC emulator — the refreshed
pc3emu-linux-x64.tar.gzcarries all of the above (banner v0.12). Runs on Linux, and on Windows via WSL2 — seeINSTALL-WINDOWS.mdinside the tarball. Needs glibc 2.43 / Ubuntu 26.04+ for the prebuilt binary; on older systems build from source (a few minutes, any distro). - Manual and development notes updated (the mouse section now documents descriptor-driven support for any standard HID mouse).
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
Pico Computer 3 v0.11 (test)
Firmware and manual for the Pico Computer 3 (RP2350B).
New in v0.11
pcmath.PIDnow matches MMBasicMATH PIDexactly — the built-in PID controller (import pcmath) has been rewritten to be numerically identical to PicoMite'sMATH PID: a trapezoidal (Tustin) integral with a dedicated anti-windup clamp, the derivative taken on the measurement (so a setpoint change causes no derivative kick) and band-limited by a first-order low-pass filter (thetauterm), all at a fixed sample timeTseconds (minimum 1 ms, as on the PicoMite).pid.update(setpoint, measured)returns the drive;pid.start(callback)/pid.stop()run the loop in the background off a hardware timer — the equivalent ofMATH PID START/STOP. Verified in the PC emulator (closed-loop step response, the derivative-filter step-kick against its closed form, and the background timer) and by the maths test-suite. See User Manual §17.- Robust on-device SQLite — the SQLite engine (
import usqlite) now runs in its own board-sized, dedicated heap, fixing a database-corruption case that could occur when the garbage collector ran while a connection was open. Two further garbage-collector-safety fixes harden it against related edge cases: bound text/blob parameters are now copied into SQLite immediately instead of referencing Python's own memory, and each open database file is pinned so it can never be reclaimed while a connection is using it. Memory use under load is also much tighter: each query's prepared statement is now freed as its cursor is consumed, so a program running thousands of queries no longer creeps toward "out of memory"; and largeORDER BY/GROUP BY/JOINoperations spill their temporary sort data to disk early instead of filling the pool — a big report that previously thrashed the board to a standstill now completes comfortably (a 20,000-row grouped report went from hanging to ~19 s at ~0.5 MB). And sorts,GROUP BYs and index builds too large to hold in memory at all now spill to a temporary file on disk and finish — where an over-large sort could previously crash the machine; a 5 MB sort that used to reset the board now completes at ~1.2 MB (spill files are created and cleaned up automatically, and default to the SD card when one is mounted — sparing the flash from a big spill's write churn — falling back to flash otherwise;PRAGMA temp_store_directoryoverrides either way).usqlite.mem_current()/mem_peak()now report real figures for watching the engine's heap. All verified on hardware across the internal flash and SD card; the API is unchanged and existing databases are unaffected. - Northwind demo + book Chapter 28 — a complete SQLite + GUI showcase application (the classic Northwind sample database, browsed on screen with
pcgui) is included as a worked example, and a new Chapter 28, "Databases" in the course book builds it up from first principles. - Course book — the new databases chapter and a new Appendix J, diagrams added across many chapters, and a proofreading pass (cross-references, typesetting, phrasing).
- PC emulator — the refreshed
pc3emu-linux-x64.tar.gzcarries all of the above (the newMATH PID, the SQLite robustness fix,import usqlite), and its display window is now resizable and scales to fit while keeping its aspect ratio. Runs on Linux, and on Windows via WSL2 — seeINSTALL-WINDOWS.mdinside the tarball. Needs glibc 2.43 / Ubuntu 26.04+ for the prebuilt binary; on older systems build from source (a few minutes, any distro). - Manual and development notes updated throughout.
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
Pico Computer 3 v0.10 (test)
Firmware and manual for the Pico Computer 3 (RP2350B).
New in v0.10
- On-device SQLite —
import usqlite— a full SQLite 3.47 database engine is now built into the firmware.usqlite.connect("/data.db")gives you real SQL — tables, indexes, transactions, parameterised queries and cursors — with the database an ordinary file on the flash disk (/) or SD card (/sd) that survives a power-cycle. SQLite runs in the board's 8 MB PSRAM heap, so non-trivial queries are practical. Hardware-tested (create/insert/select,REALround-trip, persistence across reconnect). The PC emulator has it too, soimport usqlitebehaves identically there. See User Manual §17. - USB gamepad —
gamepad()— plug a USB game controller into the host port and read it like MMBasic'sDEVICE(GAMEPAD):gamepad("LX"/"LY"/"RX"/"RY")analog sticks,gamepad("B")button bitmap (test with& gamepad.A,gamepad.START, …),gamepad("H")d-pad/hat, the analog triggers, and the PS4 gyroscope/accelerometer. Xbox, PlayStation 3/4 and a table of common generic HID pads decode out of the box;gamepad.configure()teaches it an unrecognised controller (gamepad.monitor()helps discover one). Hardware-tested with a generic pad and a DualShock 3. - USB serial (CDC host) —
USBSerial— a USB-serial adapter (FTDI, CP2102, CH340, or a native-USB device such as an Arduino) plugged into the host port becomes a UART-like object: exactly theread/readline/readinto/write/flush/anyofmachine.UART, plusconnected()andon_change()for hot-plug. Up to four at once. Hardware-tested round-trip against a second RP2 running MMBasic. hdmi.RGB320_8— 320×240 in 256 colours, pixel-doubled to 640×480. One buffer is only a quarter of the video SRAM, so the display, the overlay layer and the off-screencreate()buffer all fit in fast SRAM at once — the only mode offering an overlay and a fast double buffer together.- Wi-Fi password security — the saved Wi-Fi password is now scrambled and tied to this specific board (not readable at a glance in
settings.json, and useless if copied to another board), andwifi("SSID", "pw", save=False)connects without saving it. - Fixes — a composite keyboard's extra HID interface (e.g. the Raspberry Pi keyboard's media keys) no longer shows up as a phantom gamepad; RGB640_4
vsynctiming; the cosmetichardware/powman.hbuild error on RP2350; and the emulator now builds cleanly from a fresh clone. Built against pico-sdk 2.3.0 with an upstream MicroPython sync. - Manual and development notes updated throughout.
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
The PC emulator
New with this release: pc3emu-linux-x64.tar.gz — the Pico Computer 3 as a PC program. The same interpreter, drawing code, keyboard decoding, audio and Python toolkit as the firmware, with the hardware provided by SDL2: it boots to the banner and >>> in a window and runs the book's programs unmodified (the SD card comes pre-seeded with them). Runs on Linux, and on Windows via WSL2 — INSTALL-WINDOWS.md (also inside the tarball) walks a machine that has never seen WSL all the way to the running emulator, no Linux experience or compiler required. The release assets were refreshed on 22 July to add on-device SQLite (import usqlite) to both the firmware and the emulator; an earlier 18 July refresh brought firmware and emulator onto the same tree, pico-sdk 2.3.0 and an upstream MicroPython sync (including a fix for pin interrupts on GPIOs above 30).
Compatibility: the prebuilt emulator binary needs glibc 2.43 or newer — Ubuntu 26.04+ (on older releases it stops with version `GLIBC_2.43' not found). On Windows/WSL, install the right version by name: wsl --install -d Ubuntu-26.04 (details in INSTALL-WINDOWS.md). On an older Linux, build from source instead — it works on any distro and takes a few minutes. Clone with git; GitHub's source ZIP/tarball won't build (it lacks the submodules):
sudo apt install -y git build-essential libsdl2-dev python3
git clone --branch pico-computer-3 https://github.com/UKTailwind/micropython
cd micropython
make -C mpy-cross -j$(nproc)
make -C ports/unix VARIANT=pc3 submodules
make -C ports/unix VARIANT=pc3 -j$(nproc)
chmod +x ports/rp2/boards/PICO_COMPUTER_3/emulator/pc3emu
ports/rp2/boards/PICO_COMPUTER_3/emulator/pc3emu
Pico Computer 3 v0.9 (test)
Firmware and manual for the Pico Computer 3 (RP2350B).
New in v0.9
- 3D engine —
draw3d— MMBasic's DRAW3D ported as a module: quaternion-rotated polyhedra with backface culling, painter depth-sorting, per-face colours/fills/flags/lighting, and hidden-line rendering (depthmode=2, the z-buffer wireframe mode — the Elite look). Demos:tests/football.py(Peter's bouncing truncated icosahedron),tests/elite.pyandtests/cobra.py(hidden-line wireframe ships). hdmi.RGB640_4— 640×480 in 16 colours, the fast game mode: the 150 KB framebuffer is half the video SRAM, sohdmi.create()'s off-screen F buffer takes the other half. Double-buffered 3D now runs faster than MMBasic on the same hardware.- RGB320 fast double-buffering —
hdmi.create()called beforehdmi.layer()claims the second half of video SRAM for the F buffer (first come, first served;layer()then errors untilclose("F"); calllayer()first and both coexist as before). - Turtle pattern fills —
t.fillpattern(0..31)(fp), MMBasic's 32 8×8 fill patterns, plus a fix for the speckled border artefact on filled shapes;hdmi.polyfill()exposes the scanline pattern fill to everything else. pcmath.AHRS— Mahony and Madgwick sensor fusion (MMBasicMATHverbatim) for IMU work: feed gyro/accel (/mag), get quaternion or Euler angles.- Overclock flash fix —
screen(..., 315)/screen(..., 378)no longer hard-hangs: the post-write XIP re-entry now respects the flash's limits at every supported CPU clock (PICO_FLASH_SPI_CLKDIV=4, MMBasic's setting). - 4-bpp modes corrected — all C drawing paths now share framebuf's GS4_HMSB nibble order; RGB1024 text and graphics render with columns the right way round.
- Console robustness — Ctrl-C during a dupterm write no longer kills the screen console;
run()always restores drawing (and the console) to the visible display when a program ends, however it ends — no more "dead REPL" after interrupting a double-buffered program. - Performance — the 3D engine and drawing core use single-precision hardware FPU arithmetic and horizontal-span fills throughout (MMBasic parity).
pyeeditor sizing — the editor takes its screen size from the active console, fixing the bottom line in RGB320.run()arguments —run("prog.py", "in.wav", 10)hands the program its command line insys.argv, exactly as desktop Python (and MMBasic'sRUN "prog", cmdline/MM.CMDLINE$); arguments arrive as strings,argv[0]is the program path.- Manual and development notes updated throughout.
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
The PC emulator
New with this release: pc3emu-linux-x64.tar.gz — the Pico Computer 3 as a PC program. The same interpreter, drawing code, keyboard decoding, audio and Python toolkit as the firmware, with the hardware provided by SDL2: it boots to the banner and >>> in a window and runs the book's programs unmodified (the SD card comes pre-seeded with them). Runs on Linux, and on Windows via WSL2 — INSTALL-WINDOWS.md (also inside the tarball) walks a machine that has never seen WSL all the way to the running emulator, no Linux experience or compiler required. The release assets were refreshed on 18 July: firmware and emulator now build from the same tree, which also brings pico-sdk 2.3.0 and an upstream MicroPython sync (including a fix for pin interrupts on GPIOs above 30).
Compatibility: the prebuilt emulator binary needs glibc 2.43 or newer — Ubuntu 26.04+ (on older releases it stops with version `GLIBC_2.43' not found). On Windows/WSL, install the right version by name: wsl --install -d Ubuntu-26.04 (details in INSTALL-WINDOWS.md). On an older Linux, build from source instead — it works on any distro and takes a few minutes. Clone with git; GitHub's source ZIP/tarball won't build (it lacks the submodules):
sudo apt install -y git build-essential libsdl2-dev python3
git clone --branch pico-computer-3 https://github.com/UKTailwind/micropython
cd micropython
make -C mpy-cross -j$(nproc)
make -C ports/unix VARIANT=pc3 submodules
make -C ports/unix VARIANT=pc3 -j$(nproc)
chmod +x ports/rp2/boards/PICO_COMPUTER_3/emulator/pc3emu
ports/rp2/boards/PICO_COMPUTER_3/emulator/pc3emu
Pico Computer 3 v0.8 (test)
Firmware and course book for the Pico Computer 3 (RP2350B).
New in v0.8
cls()— clear the console screen (MMBasicCLS).fmmulti-select — Space selects several files (shown yellow, counted in the status line); C/M/D copy, move or delete the whole selection. Plus a guard: copying when both panes show the same directory is refused (it would have truncated the source).- Readable tracebacks from
run()— errors now reportFile "prog.py", line Ninstead of<string>. console("none")— no console output anywhere and no blinking cursor over full-screen graphics; input still works,console()restores.- DS3231 daily alarm —
ds3231.set_alarm(h, m),alarm_fired(),clear_alarm(),alarm_off(),alarm_pin()(INT wired to GP32). Survives resets — it lives in the battery-backed chip. pccursor— a visible mouse pointer (MMBasicGUI CURSOR): save-under sprite, ARROW/CROSS shapes;pcguishows and refreshes it automatically when a mouse is present.- The book — Programming the Pico Computer 3: a complete 34-chapter beginner-to-advanced course with 9 appendices (including a full MMBasic→Python translation table). Source in
boards/PICO_COMPUTER_3/book/(build the PDF withmakethere). - Manual and development-notes updates throughout (auto-run, import paths, hardware alarm, cursor, plus a fix to the GUI skeleton example).
Flashing
USB HUB switch to DISABLE → connect the Prog port to a PC → hold BOOT, click RESET → drag firmware.uf2 onto the drive that appears → switch back to ENABLE. Your files and settings survive.
Pico Computer 3 v0.7 (test)
A customised MicroPython build for the Pico Computer 3 (RP2350B) that turns it into a self-contained computer: HDMI display, USB keyboard/mouse/touch, SD card, audio, real-time clock and Wi-Fi — all from the Python prompt. This release rounds out the "standalone computer" experience.
New since v0.6
- File manager —
fm()— a dual-panel file manager (MMBasic FM). Two panes side by side: Tab / ←→ switch panes, arrows navigate, Enter opens by type (.pyruns, audio plays, images show, text views), and C copy / M move between the panes. Plus edit (pye), delete, rename, mkdir, and audio controls. Incremental redraw keeps it snappy; it restores the video mode after a program changes it. - Plotting —
plot()— one-call plotting on the screen for maths/science: a list, several series, or a function over a range; line / scatter / bar, autoscaled with axes and range labels. - Game-loop timing —
pcgame.Clock— a drift-free fixed-cadence frame clock (MMBasicSYNC):tick()holds an absolute deadline so animation runs at a steady rate with no drift, returnsdtfor frame-rate-independent motion, and tracks.fps(orvsync=Trueto lock to the display refresh). - Maths helpers —
pcmath— the MMBasicMATHverbs thatulabdoesn't already cover: quaternions, 3-D vectors, DSP (window / sinc / crossings / power spectrum), correlation, chi-square, and a PID controller. (Statistics, linear algebra, FFT and complex are inulab+cmath.) autosave("file")— capture what you paste or type at the console straight into a file (MMBasic AUTOSAVE) — the frictionless way to get a program onto the board with no XMODEM or SD-card shuffling. Ctrl-Z saves.
See DEVELOPMENT_NOTES.md (§45–§49) and USER_MANUAL.md for details.
Install
Hold BOOTSEL while powering on, then copy firmware.uf2 to the RPI-RP2 drive. The board reboots into this build; the REPL banner reports PICO COMPUTER 3 v0.7.
Test release — for evaluation on the Pico Computer 3 board.
Pico Computer 3 v0.6 (test)
A customised MicroPython build for the Pico Computer 3 (RP2350B) that turns it into a self-contained computer: HDMI display, USB keyboard/mouse/touch, SD card, audio, real-time clock and Wi-Fi — all usable from the Python prompt.
New since v0.5
- Turtle graphics — a
Turtleclass (MMBasicTURTLE): movement/pen/heading, arcs, Béziers, circles, filled polygons, a state stack. - Bitmap fonts — the full set of nine MMBasic fonts (8×12 up to 32×50).
hdmi.text(s, x, y, fg, bg, scale, font),hdmi.fonts(), andDisplay.text(..., font=, scale=). - GUI toolkit (
pcgui) — the complete MMBasic GUI control set as Python objects: caption, frame, button, switch, checkbox, radio, LED, gauge, bar gauge, slider, text/number box, display box, spinner, list box, format box, and area. Driven by a USB mouse or touch panel, with an on-screen keyboard/keypad for touch text entry and global touch hooks (theGUI INTERRUPT TouchDown/TouchUpequivalent). Flicker-free incremental gauges/sliders. - Tile maps (
TileMap) — scrolling tile-map backgrounds with a fast C render loop (hdmi.tilemap), tile attributes and collision, and single-tile drawing (blit_tile). Ships with a Breakout game demo (tests/breakout.py) ported from MMBasic.
See DEVELOPMENT_NOTES.md (§42–§45) for the implementation details and USER_MANUAL.md for usage.
Install
Hold BOOTSEL while powering on, then copy firmware.uf2 to the RPI-RP2 drive. The board reboots into this build; the REPL banner reports PICO COMPUTER 3 v0.6.
Test release — for evaluation on the Pico Computer 3 board.
Pico Computer 3 v0.5 (test)
Pico Computer 3 v0.5 (test)
A MicroPython (RP2350B) firmware for the Pico Computer 3 standalone board.
Install
Hold BOOTSEL while powering up, then copy firmware.uf2 to the RPI-RP2
drive that appears. The board reboots into MicroPython; the REPL banner reads
MicroPython v1.29.0-preview on PICO COMPUTER 3 v0.5 with RP2350B.
What's new since v0.4
On-screen colour editing
- The HDMI console now understands ANSI colour (SGR escapes) — 16-colour
foreground/background, bold and reverse work on the screen as on a serial
terminal. - The
pyeeditor syntax-colours.pyfiles using MMBasic's scheme —
keywords cyan, strings magenta, comments yellow, numbers green — plus a
coloured status bar and selection.pye.Editor.syntax = Falseturns it off.
Wi-Fi + NTP time
wifi("SSID", "password")connects and remembers the credentials;
ntpsync()sets the clock from an internet time server and updates the
battery-backed DS3231 (so the time stays right offline).tz(hours)sets
the timezone offset;auto(True)syncs at every boot.- Credentials are stored in plaintext in
/settings.json(this board has no
secure storage) — see the manual's note and the per-session alternative.
Richer 2D drawing primitives
On the Display from hdmi.fb(), beyond framebuf's line/rect/ellipse/poly:
d.line(x1,y1,x2,y2,colour,w)— thick lines.d.rbox(x,y,w,h,r,colour,fill=None)— rounded rectangles.d.arc(x,y,r1,r2,a1,a2,colour)— filled arcs / ring segments.d.bezier(points,colour)— Bézier curves.d.flood(x,y,colour,border=None)— flood fill (paint-bucket or
fill-to-boundary), in C, in every video mode.
Sprite sheets — load_image() / Image
load_image(path)decodes a.png/.jpg/.bmpinto memory in the
current pixel format, returning anImageyou can blit whole or in pieces —
the standard way to hold a sprite sheet and blit individual sprites out
of it.Image.blit()/Image.cell()blit straight from RAM;transparent=
makes a PNG's alpha a skip colour.Image.sprites(cw, ch)cuts a sheet into sprite-engineSprites that
share the one buffer (no per-sprite copy);sprite.frame(n)animates
a sheet-backed sprite through its frames.tests/demo_asteroids.pyshows a 64-frame asteroid sheet animated and
double-buffered in Python (hdmi.create()+hdmi.vsync()/hdmi.copy()) for
tear-free motion.
See USER_MANUAL.md (in the board directory) for full documentation.
Pico Computer 3 v0.4 (test)
Pico Computer 3 v0.4 (test)
A MicroPython (RP2350B) firmware for the Pico Computer 3 standalone board.
Install
Hold BOOTSEL while powering up, then copy firmware.uf2 to the RPI-RP2
drive that appears. The board reboots into MicroPython; the REPL banner reads
MicroPython v1.29.0-preview on PICO COMPUTER 3 v0.4 with RP2350B.
What's new since v0.3
Audio: tracker music, tones and a synthesiser
- MOD tracker playback —
play("/sd/song.mod", loop=True)plays Amiga MOD
music with the hxcmod engine (returns the song title).mod_sample(n)fires
one of the module's instrument samples as a sound effect mixed over the
running music — background music plus game SFX from a single file. tone(left, right, ms)— two independent sine-wave channels. Calling
tone()again while one plays retunes it seamlessly (click-free), so
melodies and arpeggios work.sound(voice, side, wave, freq, vol)— a 4-voice synthesiser with
sine / square / triangle / sawtooth / periodic-noise / white-noise waveforms
per voice and side; volume changes ramp to avoid clicks.pause()/resume()for the current playback.
Graphics: layers, off-screen buffers, a blitter and a sprite engine
- Overlay layer + off-screen framebuffer —
hdmi.layer()adds a
transparent overlay merged live over the display (RGB320);hdmi.create()
adds an off-screen buffer in PSRAM.hdmi.write("N"/"L"/"F")chooses where
all drawing goes (including the image loaders and console), and
hdmi.copy(src, dst)block-copies whole buffers. hdmi.blit(x, y, w, h, x1, y1, src, dst, skip)— a rectangle blitter
that copies within or between buffers (or to/from RAM(buffer, w, h)
surfaces), with an optional skip colour for cut-out sprites; overlapping
copies are safe in any direction.hdmi.vsync()— wait for vertical blanking for tear-free updates and
frame pacing (input and audio keep running while it waits).pcsprite— a full sprite engine (import pcsprite): layers, AABB
collisions (sprites, screen edges and static walls, edge-triggered), z-order
and background scrolling — MMBasic sprite semantics on a dirty-rectangle /
overlay-layer compositor.update()commits moves and returns collisions.
Input
keydown(n)— read which keys are held right now (not just typed
characters) — essential for games: count, per-key codes, modifier and lock
bitmaps.keyboard.on_key(cb)— a callback on every keypress / auto-repeat.- Num Lock now defaults on and, when off, the numeric keypad acts as the
navigation cluster (arrows / Home / End / PgUp / PgDn / Ins / Del).
Console
console("both" / "serial" / "screen")routes console output
(MMBasicOPTION CONSOLE) — keep prints off the HDMI screen while testing
graphics, or off the serial port; keyboard input always works. Power-up
default isboth.- On-screen editor scrolling now works: the
pcconsoleterminal emulator
gained a scroll region (DECSTBM) and reverse index, so thepyeeditor
scrolls correctly on the HDMI screen (not just over serial).
Reliability
- DS3231 RTC survives a live CPU-clock change — the I2C bus is rebuilt when
screen(mode, 315/378)changes the clock, sogettime/settimestay
correct. - On-device test suite —
boards/PICO_COMPUTER_3/tests/(copy to the SD
card,run("test_all.py")): pixel-verified automatic tests for the blitter,
buffers, sprites and images, plus interactive tests for the keyboard, audio
and console routing.
See USER_MANUAL.md (in the board directory) for full documentation.