brightness-living-room-sync.yaml 505 Bytes
Newer Older
Erick Hitter's avatar
Erick Hitter committed
1 2 3 4 5 6
alias: Brightness Living Room Sync
trigger:
  - platform: state
    entity_id: light.endtable
  - platform: state
    entity_id: light.corner_table
Erick Hitter's avatar
Erick Hitter committed
7 8 9 10 11 12 13 14 15
condition:
  condition: and
  conditions:
    - condition: state
      entity_id: light.endtable
      state: 'on'
    - condition: state
      entity_id: light.corner_table
      state: 'on'
Erick Hitter's avatar
Erick Hitter committed
16
action:
Erick Hitter's avatar
Erick Hitter committed
17
  service: input_number.set_value
Erick Hitter's avatar
Erick Hitter committed
18
  data_template:
Erick Hitter's avatar
Erick Hitter committed
19
    entity_id: input_number.brightness_lr
Erick Hitter's avatar
Erick Hitter committed
20
    value: '{{ trigger.to_state.attributes.brightness|float }}'