24 Feb 2024, 21:35

An Update to the Pantry Door Warning Light

One thing I’ve learned from my pantry door warning light is that SD cards don’t last forever and it gets pretty old to build a fresh Raspbian install and set up my Blinkt light server (and Tailscale) whenever a card gives out. I kept looking for something that would let me easily build (and update and rebuild) a ready to boot image so that I could just flash a new SD card and be on my way. It took a while but I finally found it with Gokrazy. Thanks to this helpful Gokrazy guide I was able to get an image built with Tailscale preconfigured so that the Pi would join my Tailnet immediately on first boot. Installing my Blinkt light server was just as simple, although I did have to rewrite part of it to use the fantastic periph.io library for GPIO to control the Blinkt strip since the sysfs-based approach I used before wasn’t supported in the Gokrazy kernel. Now the next time I have an SD card failure I’ll just pop a fresh card in the laptop, run gok overwrite and put the card in the Raspberry Pi Zero 2W and be up and ready to monitor the state of the pantry door from the garage in no time.