thermo

Make it yours

Customize or port thermo with an AI coding agent

thermo does what one household needed, on Linux. Yours may need macOS, a headless Raspberry Pi feeding Grafana, Fahrenheit, or a different thermometer. You don't have to wait for someone to add it. A coding agent can do most of the work, and the repository is set up to help it.

Why this code base is agent-friendly

Architecture: portable crates bthome and calibration, protocol encoding in atc, and the platform-specific Bluetooth transport, scanner and chart transfer that a port replaces thermo app state · keys · table · chart layout · CSV store scanner · kitty shm atc commands as bytes transport bthome 0 deps · pure calibration 0 deps · pure BlueZ (Linux) swap for btleplug → CoreBluetooth (macOS) · WinRT (Windows) replace when porting
Dashed boxes are what a port replaces. The filled crates come along unchanged.

How to do it

  1. Get the code and an agent.

    Clone the repository and start your agent in it, for example Claude Code:

    git clone https://github.com/arturzielazny/atc-thermo
    cd atc-thermo
    claude
  2. Ask for a plan first.

    For anything bigger than a tweak, ask the agent to read AGENTS.md and propose a plan before editing. In Claude Code, plan mode (Shift+Tab) does exactly that.

  3. Let it build and test in a loop.

    Tell it the finish line: "cargo test --workspace and cargo clippy -- -D warnings pass". Agents work best when they can check themselves.

  4. You test with hardware.

    The agent can't see your thermometers. Run the result, check the readings, then try one write action (rename is the safest) on one device before calibrating all of them.

Prompts to start from

Copy one, then add your details: OS version, terminal, how many devices, what you want to see.

Port to macOS

Read AGENTS.md. Port thermo to macOS following its "Porting to another OS" section: introduce a DeviceId type instead of bluer::Address, reimplement the scanner and the atc transport with btleplug, and send chart images with direct kitty transmission instead of /dev/shm. Keep Linux working behind cfg. Plan first, then implement step by step, keeping cargo test and clippy green after each step.

Port to Windows

Read AGENTS.md. Make thermo build and run on Windows 11 with btleplug (WinRT). Store history under %LOCALAPPDATA%. Windows Terminal has no kitty graphics, so make sure the braille chart fallback is used. Keep the Linux build unchanged. Plan first.

Headless Raspberry Pi exporter

Read AGENTS.md. Add a new binary crate thermo-mqtt that reuses the scanner and the bthome crate, without the TUI, and publishes every reading to MQTT as JSON (topic thermo/<name>), with Home Assistant MQTT discovery. Add a systemd unit file and a README section for Raspberry Pi OS.

InfluxDB / Grafana

Read AGENTS.md. Add an optional InfluxDB line-protocol writer to thermo, configured by environment variables, that sends each advert (temperature, humidity, battery, RSSI, device name). Don't block the UI on network errors.

Fahrenheit

Read AGENTS.md. Add a °F display option (key: u) to thermo. Keep storage and calibration in °C, convert only for display in the table, chart axis and calibration panel, and remember the choice across restarts.

Another pvvx device

Read AGENTS.md. I have <model> thermometers on pvvx firmware <version>. Compare its config layout and LCD limits in the pvvx sources with crates/atc/src/config.rs and screen.rs, and make identify, settings and calibration work for it. Don't connect to any device; I'll test.

Keep your devices safe. Agents should never run write actions against your thermometers unasked, and AGENTS.md tells them so. Calibration is reversible (x restores factory coefficients), and a mistaken setting can be fixed again from thermo or the pvvx web flasher, but it's still your call.

Share what you build

A port or a feature that others could use? Open a pull request or an issue on GitHub. Say which agent you used and which hardware you tested on.