i have code below, but the state of my switch doesnt change, if i do a test and change the input boolean to on / off (manually) , the switch doesnt change state
from template editor, this command gives me true/false, so it seems correct
i dont have any commands to return , it doesnt even change when i manually turn on/off the input_boolean from states page
then even the switch doesnt change state
for testing i am changing the input_boolean manually in the states pages
so if i turn on/off the boolean, the change for my switch should normally change
Well, easy , when I restart hassio, I want the button to remember the state like it was before… That’s why I want to use an input Boolean… Those don’t loose state after a reboot
Ok… So you just want a “switch” that doesn’t actually do anything. That you will turn off and on with a later automation. And that you can display it’s state. But it has to remember it’s state across reboots. Is that correct?
If so then that sounds like you just need to create an input Boolean and forget about all of the rest of the extra stuff you are doing. Then just turn the Boolean off and on directly on the frontend.
ow indeed, but my command on/off is actually a TCP commandline
so yes, i need to create a template switch, with the on/off command to fire my command line switch
strange that it doesnt work with a command line switch