Some time ago I've installed Home Assistant. I continue to play with this awesome thing.
For a couple of year I own a simple humidifier Venta LW25. It is very simple device, no WiFi, no ZibBee.
Venta LW25 has only two buttons: on/off and the button to switch mode. There are 3 modes available: low, medium, high. And that's all. Very simple and clear device.
The blue circle is on when the device is on. There are also 3 numbers and a triangle. Only one of that symbol can be on. The number means the current working mode of the device. The triangle is on when there is no water in the device (and the light for the triangle is red).
Pressing the switch mode button changes the working mode. If it is mode 1, then pressing the button will turn on mode 2. If the mode is 3, then the mode will be changed to 1 after pressing the button.
I always select mode 2. On the 3rd mode the humidifier is too loud.
If you unplug this device from the power socket and plug it again, then the device will return to the mode it had before unplugging.
There was an unused smart plug TP-Link HS110 in my home. That is a pretty neat device. You plug it into the power socket and then you plug the device of your choice (lamp, heater, something like that) into that TP-Link smart plug. After that you can turn on/off the device from your phone. And this smart plug also measures the power consumption.
And in the name of science I've plugged my humidifier into that smart plug.
There wasn't any particular task that I wanted to solve by this action, I was just curious will it give me something.
Well, it turned out that there is something interesting that can be taken from the power consumption data. On the graph it is perfectly visible what is the state of the humidifier and when it run out of water.
Here is a graph from Home Assistant:
So, from this smart plug data it is possible to know the state of the humidifier. To make it more clear I've created in Home Assistant a new sensor that shows the state of the humidifier base on the power consumption.
Here is the part of configuration.yaml:
- platform: template
sensors:
humidifier_state:
value_template: >-
{% if states("sensor.tplink4_watts") | float < 0.01 %}
off
{% elif states("sensor.tplink4_watts") | float > 0.5 and states("sensor.tplink4_watts") | float < 1 %}
empty
{% elif states("sensor.tplink4_watts") | float > 1.6 and states("sensor.tplink4_watts") | float < 2.4 %}
mode_1
{% elif states("sensor.tplink4_watts") | float > 3 and states("sensor.tplink4_watts") | float < 3.6 %}
mode_2
{% elif states("sensor.tplink4_watts") | float > 5.5 and states("sensor.tplink4_watts") | float < 6.5 %}
mode_3
{% else %}
unsure
{% endif %}
And here is the screenshot of Home Assistant user interface:
In theory, that sensor can be used in automation. When the humidifier run out of water it sends me message that I need to fill it. But in practice, there is no much sense in it. When you are in the room with humidifier it is very visible that there is no water in the device (the red LED is shining)
But now I have data how much time does it take it to use all the water. Now I have two measurements. In the first the humidifier was empty after 27 hours of work, the second time it run out of water in 30 hours. So if I just need to fill it once a day and in this case it will never run out of water.
So, with just one smart plug I can not only switch on/off this device, but also know it's state. But, I can't switch states. It is possible to add one more device, some button presser and then all the humidifier features will be available via Home Assistant (but in the perfect world you don't need to fill the humidifier, there is a hose, that automatically fills it when it is needed).
13 february 2020
This text is also available in Russian language |