Close

Software platform: ESPhome

A project log for The Water Watcher

Monitoring the pilot light on my water heater.

WJCarpenterWJCarpenter 01/15/2021 at 04:040 Comments

For some other projects, including the sensors already scattered around my house, I was already using ESPhome. The strength of ESPhome is that it makes it very, very easy to deploy standard sensors and a cornucopia of other devices. It provides the glue logic and mundane code to run the devices, and it also provides wifi connectivity, over-the-air updates, connectivity to Home Assistant, connectivity to an MQTT broker, and many other niceties. Most "programming" for ESPhome is done with YAML configuration, though there are escape mechanisms for doing things in C++ if and when you need them.

You can find copies of my ESPhome configurations in the "Files" section of this project. I'm not spending any time describing the ESPhome framework because there is plenty easy-to-find of documentation for it. Likewise for setting up an MQTT broker. (I use mosquitto, and you probably will, too, if you don't already have an MQTT broker.) My configuration files stand alone and also have plenty of comments. (Those comments aren't really for you. They are for me for when I look at the files after some time has passed.)

At the time I deployed the Water Bug and planned to have it monitor the pilot light, I wasn't sure what I was going to do to receive the pilot light status messages at the other end. I thought I might have Home Assistant trigger some kind of notification (and I still might in the future). But, since ESPhome allows devices to both send and receive MQTT messages, and since I already had an MQTT broker on my network for other reasons, I decided to have the Water Bug simply broadcast the pilot light status over an MQTT topic every 30 seconds. That makes it independent of having Home Assistant, though Home Assistant happens to be one of the clients that receives those messages.

Discussions