Hi
I got help with an automation a while back that looks like this:
service: climate.set_hvac_mode
target:
entity_id: climate.molnet
data:
hvac_mode: '{{ trigger.id }}'
I would like to do a similiar trigger based automation for lighting, just to simply my code and how things work, but there is no “light_mode:” option available, if I want the light to be “on” or “off” based on my trigger settings is there any way?
As it is now I “toggle” the lights when each trigger happens, but that is not always correct because sometimes on or a few of those lights have a different state then the others and things get messed up.
I can always just write two automations one for the “on” trigger and one for the “off” trigger, but the question is, can you do it with just one and use trigger_id to decide what is going to happen?