- Extract design tokens to firmware/src/theme.h (THEME_BG, THEME_PANEL, THEME_TEXT, etc.); ui.cpp aliases COL_* to the THEME_* tokens - Splash container + canvas COL_EMPTY now use THEME_BG / 0x0000 instead of the hardcoded 0x0f0f0f / 0x10A2 dark grey - tools/convert_to_c.js maps "transparent" palette entries to 0x0000 (true black) so regenerated splash_animations.h matches the new bg - Re-regenerate splash_animations.h - Convert logo to RGB565A8 (alpha plane) so it composites against any background — no more grey halo around the upper-left logo on screens where the bg differs from the previous baked-in 0x18E3 color
Splash animation tools
Two-step pipeline for getting third-party 20×20 pixel animations onto the device.
1. Scrape
node scrape_claudepix.js
Fetches the manifest from claudepix.vercel.app/app.js, then each animation's
HTML file, evaluates the embedded JS in a Node VM context (loading the same
creature-engine.js the site uses), and writes resolved frame data to
tools/claudepix_data/*.json.
Each output file looks like:
{
"filename": "idle_breathe.html",
"name": "idle breathe",
"category": "Idle",
"description": "...",
"frame_count": 17,
"frames": [{ "hold": 500, "grid": [[0,0,...],[0,1,1,...],...] }, ...]
}
Override URL or output dir with --base and --out.
2. Convert to C
node convert_to_c.js
Reads tools/claudepix_data/*.json and emits a single
firmware/src/splash_animations.h with:
splash_<ident>_frames[N][400]— per-frame cell codes (0 = empty, 1 = body, 2 = eye)splash_<ident>_holds[N]— per-frame hold time in mssplash_anims[]— master table with name, category, frame count, pointersSPLASH_ANIM_COUNT
The firmware (splash.cpp) consumes this header to render and animate.
Re-running
The scraper is idempotent — re-run any time the source library updates. The converter overwrites the header. Rebuild firmware after running both.
License note
The scraper hits a public site without a stated license. Confirm reuse is appropriate for your case before redistributing the output.