Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - alias: "Tænd lyset ved bevægelse"
- initial_state: true
- mode: parallel
- trigger:
- - platform: state
- entity_id:
- - binary_sensor.tradfri_motion_sensor
- from: "off"
- to: "on"
- action:
- - service: script.turn_on
- data_template:
- entity_id: script.generic_sensor_dimmer
- variables:
- sensor: "{{ trigger.entity_id }}"
- light: >-
- {%- if trigger.entity_id == "binary_sensor.tradfri_motion_sensor" %}
- light.sandbox_bulb
- {%- elif trigger.entity_id == "binary_sensor.other_sensors" %}
- light.indgang
- {% endif %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement