Rewriting an air quality dashboard from Streamlit to Rust
The setup
An IKEA ALPSTUGA sensor measures indoor air and talks Matter over Thread. Readings flow through an Apple Shortcuts automation that appends them to a CSV file on the home server. The dashboard reads that file and charts it.
Why move off Streamlit
Streamlit made the first version quick to build, but for a dashboard that runs 24/7 on a small server it was heavier than it needed to be: a full Python runtime, a websocket session per viewer and a slow cold start.
The Rust version
The rewrite, aq-dash, is a single small binary. It parses the CSV, serves one page and a JSON endpoint for the charts, and is started automatically at boot by a launchd daemon.
What's next
An e-paper display on the desk, fed from the same JSON endpoint, so the numbers are visible without opening a browser.