Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 102110

Help me understand scenes

$
0
0

@dsonenberg wrote:

I have several automations I would like to build that would control multiple lights, and I thought it would be best to use scenes to accomplish this. If i create this scene:

- name: BasementLightsOn
  entities:
    switch.basement_light_1:
      state: on
    switch.basement_light_2:
      state: on

and activate it by:

- alias: Turn on basement light when there is movement
  trigger:
    platform: state
    entity_id: binary_sensor.basement_motion_1_sensor
    to: 'on'
  action:
    service: scene.turn_on
    entity_id: scene.BasementLightsOn

Do i need to make a second scene to turn the lights off or can I simply use:

scene.turnoff

TIA

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 102110

Trending Articles