Select Page

I’m a huge home automation fan, my house is basically a robot controlled by Home Assistant and many, many, sensors, smart devices and microcontrollers.

One of the things I’ve automated is the garage door, which operates from your standard key fob controls but also has connectors on it’s controller board for simple switches for open and close. Since a simple pair of dry relays can be connected to them as they’re not really handling any significant current, it should be a simple job I thought.

I’ve got lots of ESPHome devices in my house, mostly running on ESP32s (with a couple of ESP8266s) but at the time the Pi Pico W was newly supported so I thought I’d give it a try since I found a decent dual-relay module that plugs straight into it and didn’t require extra power beyond standard USB.

Initially I struggled as it turned out that the Pico W would go into a boot loop if its WIFI was set to use DHCP1, so it had to have a static IP address for it to work, and there was no integrated support for the Pico within Home Assistant so it had to be done from the Esphome command line, but as I was born to the command line, shaped by it, it wasn’t an issue.

Once it was up and running, controlling the garage door via Home Assistant was a breeze and I created many an automation for it and life was good.

Until it wasn’t.

Many months after getting it working, the garage door stopped working from within Home Assistant, it was complaining it needed to be reconfigured due to an encryption change, but it simply wouldn’t update. And more bizarrely it was claiming to be a Bluetooth extender in the error message, another use of ESP32s that ESPHome makes super easy, and I have a couple of those assisting in the house too.

Manually reflashing the Pico over a USB didn’t appear to help either, it would flash, then still not work and wasn’t visible on the network.

After many attempts to get it working, I remembered the manual fixed ip address that was required for the Pico W to boot, so I removed it on the chance it was a WiFi issue and, once again, it went into a boot loop. But on a whim I pinged the fixed IP address with the Pico offline and somehow it was still responding like a ghost. Or rather, it turned out, the Bluetooth proxy was, which had the same IP address but it was allocated to it via DHCP.

I had forgotten to give the Pico a permanent lease in the DHCP setup, so eventually the router gave that ip to something else, by sheer happenstance, that other device was also running ESPHome which cause all the confusion instead of a simple IP conflict.

Due to the rather low odds of this happening I did buy a lottery ticket, but apparently the RNG gods were not smiling on me twice.

The moral of this story? Do a proper job when fixing an ip address of an IoT device,

(Image produced using AI, obviously)

  1. It appears to be a little hit and miss as to who suffers from this issue, some on the ESPHome Discord channel have no issues with DHCP, some do. If it was easy everyone would be doing it. ↩︎