Turn on scene when front door is opened

yeah, it’s a bit unclear, which of the docs is right :wink:

I do use scenes, and always use the service: style.
Must admit though, Ive rewritten all of my scenes just today, because of the demise to the transition in the new scenes setup ( which balloob said might come back, but after having said so, it has become dead-silent on that front)

More importantly, scenes were having other issues and especially the ones might a lot of light entitities seemed to cause havoc. Rewriting them as scripts stopped all of that, and brings back the transition.

instead of calling scenes:

- name: Home theater off
  entities:
    light.buffet: off
    light.silver_cabinet: off
    light.dining_table: off
    light.lounge_chair_regular: off
    light.serre_chair: off
    light.office_inside: off
    light.master_bedroom: off
    group.bureau_lights: off
    light.living_ceiling_2_terrace: off
    light.living_ceiling_4_sofa: off

    light.hue_ambiance_spot_4: off
    light.hue_ambiance_spot_5: off

- name: Home theater on
  entities:
    light.kist:
      state: on
      brightness: 125
      hs_color: [14,83]
    light.home_theater:
      state: on
      brightness: 102
      rgb_color: [255,188,85]
    light.lounge_chair_long:
      state: on
      brightness: 102
      hs_color: [21,65]
    light.living_ceiling_1_cds:
      state: on
      brightness: 254
    light.hue_ambiance_spot_6:
      state: on
      brightness: 254

I can now do this again:

home_theater_off_lighting:
  alias: Home theater off
  sequence:
    service: light.turn_off
    data:
      entity_id:
        - light.buffet
        - light.silver_cabinet
        - light.dining_table
        - light.lounge_chair_regular
        - light.serre_chair
        - light.office_inside
        - light.master_bedroom
        - group.bureau_lights
        - light.living_ceiling_2_terrace
        - light.living_ceiling_4_sofa
        - light.hue_ambiance_spot_4
        - light.hue_ambiance_spot_5
      transition: 6

home_theater_on_lighting:
  alias: Home theater on
  sequence:
    - service: light.turn_on
      data:
        entity_id: light.kist
        brightness: 125
        hs_color: [14,83]
        transition: 6
    - service: light.turn_on
      data:
        entity_id: light.home_theater
        brightness: 102
        rgb_color: [255,188,85]
        transition: 6
    - service: light.turn_on
      data:
        entity_id: light.lounge_chair_long
        brightness: 102
        hs_color: [21,65]
        transition: 6
    - service: light.turn_on
      data:
        entity_id:
          - light.living_ceiling_1_cds
          - light.hue_ambiance_spot_6
        brightness: 254
        transition: 6

where some of these are light groups, so the affected lights are in effect a lot more than only these entities listed.
which is a huge relief…

still sorry for the demise of the scene, which was a very nice asset in the HA options. Scenes just couldn’t handle that anymore (while before it worked fine, so the new setup has really cause some pain)

Just tested using the actual front door and it didn’t work. However I changed the trigger from device, front door contact opened to state, front door off to on and that did the trick. Just incase anyone else reads this.

You really don’t need both. Just to on, or from off, should be enough. But, in any case, I’m glad you got it working.

1 Like