i’m wondering if it would be possible to create a single automation to turn off and on lights in multiple rooms.
I would like to use a variable 1: %motion sensor X and a variable 2: %light X.
Once %motion sensor X is triggered, %light X turns on
alias: PIR triggers Light generic trigger: - platform: state entity_id: sensor.%PIR_X to: 'on' action: - service: light.turn_on data: entity_id: light.%BULB_X
Does anyone knows if its possible to do that?
Thanks a lot for your help!