Hi guys, trying to figure out to use the opening/closing/stopped state from my covers, which are ESP8266 wifi relays with Tasmota (Sonoff 4CH Pro). It gives it state like this: {"Shutter1":{"Position":100,"Direction":0,"Target":100},"Shutter2":{"Position":95,"Direction":1,"Target":100}}
I want to use direction to set state_opening, state_closing like this:
Unfortunately my code also does not work, although HASS indeed does not give warnings or errors on the configuration.yaml. Is there something wrong with the template code?
This works perfectly if I change direction values.
Figured out what I did wrong: was listening to the wrong topic. I now get the correct down and up arrow when they are moving, great!
So the code now works perfectly, but I cannot find how to fix the DEPRECATED message. I found the link you posted before as well when diving into this issue. But it does not seem to help in my case If I remove the template from the configuration (i.e. leave value_template empty) the message is gone. But what is wrong with:
If it works and passes Check Configuration, don’t be concerned with what some plugin for VS Code says. It’s a plugin separate from Home Assistant. The final arbiter of what’s right/wrong is Home Assistant.