I have a script with a “Send Command” to turn a TV on. The same script will turn it off again.
How would I store the state and how would I implement that in a card in my love lace dashboard so that when I press it the ICON shows an ON TV State and if I press it again it shows an OFF State?
My idea was to use a HELPR TOGGLE but again now sure how to put it into a card or which card type to use.
@ondras12345 I have created the Template Switch. Seams to work. But how do you display the switch on the dashboard so the icon set by the template switch is diaplayed? i.e. if State is ON the icon for On is displayed and visa versa