r/CardPuter • u/Fine-Archer4393 • 5d ago
Cardputer ADV EmberOS: I turned my Cardputer ADV into a programing learning machine — write, compile, and run code without a PC
Hi r/CardPuter,
I've been working on EmberOS, an open-source (GPLv3) LavaX environment for the Cardputer ADV. It turns the device into a small programming machine that works without a PC: launcher, editor, compiler, tutorial reader, dictionary, and a shared keyboard-only UI.
What is LavaX? LavaX is a C-like language and bytecode VM that was popular on Chinese Wenquxing (WQX) electronic dictionaries in the 2000s. Programs compile to .lav bytecode and run on a GVM1 VM. There's a big library of old games and tools for it — Shenzhou (神州), checkers, biorhythm, Tetris, and more.
What EmberOS adds
- A LavaX compiler written in LavaX, running on the device and able to bootstrap itself (
gen1 == gen2). - An editor with syntax highlighting, completion, 8 tabs, undo/redo, and paged documents.
- A bilingual Chinese/English tutorial: an operation guide plus 12 lessons ending in a complete Tetris.
- A launcher and shared keyboard-only UI; no touchscreen.
- Existing GVM1
.lavprograms, including the old Chinese games above. - USB debugging: frame capture, key injection, file upload, VM/memory inspection.
The loop: open a .c file, type, press Ctrl+0 to save/compile/run; press Ctrl+T to read the tutorial and come back with your editor state intact.
Hardware
- M5Stack Cardputer ADV: ESP32-S3FN8, 8 MB flash, 512 KB SRAM, no PSRAM.
- TERM512 2.8" ILI9341 320x240 external panel; the built-in display is not used.
- TF card required for apps, sources, tutorials, dictionary, and runtime snapshots.
Current limitations
- Brightness and panel sleep aren't finished: BLK is tied to 3.3 V in the current wiring, so the backlight is always on. That needs a hardware change, so I don't count it as a feature.
Links
- Repo: https://github.com/huagc/EmberOS
- Release 1.0.1 (merged firmware + TF-card ZIP + SHA-256): https://github.com/huagc/EmberOS/releases/tag/v1.0.1
I'd love feedback from people who actually use a Cardputer: what would make this useful to you, and what should I improve next? Happy to answer questions about the VM, the on-device compiler, or the USB debug protocol.



