02Personal project · Sep 2026

Power Monitor

6,000packets in a 10-minute run · 0 dropped · 0 checksum errors

Illustration

  1. INA219
  2. Arduino Uno R3
  3. Python host

The last byte is the CRC-8/SMBUS of the 24 before it. Select any byte to flip one of its bits.

Frame accepted: the checksum matches.

Random bytes, not sensor data. The frame length, the rate, and the CRC-8/SMBUS checksum in the last byte are the project's; the contents are made up in your browser and stand for nothing.

What I did

An Arduino Uno R3 reads an INA219 current/voltage sensor over I2C. I built the circuit on a breadboard and debugged the wiring myself.

The firmware logic is integer-only C99, built with PlatformIO. It streams 10 samples per second over UART at 115200 baud, in 25-byte little-endian frames. The last byte of each frame is a CRC-8/SMBUS checksum.

On the host, a Python tool logs to CSV and plots live.

I wrote the design spec. The project also has requirements, design, task, packet-format and project-standards documents.

How it was built

I wrote the spec and directed an AI coding agent (Claude Opus 5.5 in Kiro IDE) through the implementation one task at a time, reviewing and testing every change before it was committed.

My own work: the spec, the protocol and design decisions, the hardware build and debugging, and the bench validation.

How I verified it

On real hardware, DC load voltage was within 1% and current within 2% of a multimeter, across 5 test points.

A 10-minute test logged 6,000 packets with 0 dropped and 0 checksum errors.

72 C unit tests (Unity) cover the firmware logic. 146 Python tests (pytest) cover the host tool.

The host tool has a --simulate mode, so it can be run and tested without hardware.

Tools

  • Arduino Uno R3, INA219, breadboard, multimeter
  • I2C, UART, CRC-checked serial framing
  • C99, PlatformIO, Python
  • Unity, pytest

Source on GitHub: Power Monitor