Hi
I made myself a syrup dispenser with a WEMOS and a peristaltic pump in ESPHome, that pumps for 4 seconds and reverses for 300ms (to avoid dripping afterwards). Now I would like to have a counter in hassio, that I can reset once a month (just for the fun of it), which is incremented from ESPHome, so I don’t have to add another automation for this.
my question: how can I tell hassio to increment a counter from an ESPHome device?
Here’s the ESPHome yaml:
wow, it works like a charm, thanks. I very much appreciate the quick and complete answer
although I had to put ‘’ around value, didn’t quite understand why, but it works:
This is an old topic, which actually helped me. But I found a simpler answer. Just add this code in your YAML configuration and should do the trick. No local variables needed.
- homeassistant.service:
service: counter.increment
data:
entity_id: counter.my_counter # Helper must be added to Hassio