Help with my Automations

Hi, I have been struggling with my first few automations for several weeks now. No matter what I try (pulled from various other threads here and on other sites) I can’t get my automations to trigger.

Can you see any issues with my yaml entries below? I have 3 automations that are supposed to do the following:

  1. open my blinds at 3pm
  2. turn on outside lights 15 minutes before sunset
  3. turn on my HRV (wave appliance module) for 12 hours starting at 9pm

Thanks in advance.

- id: '1558531453857'
  alias: Blind Schedule
  - at: '15:00:00'
    platform: time
  - condition: state
    entity_id: cover.somfy_unknown_type_5a52_id_5401_level
    state: ready
  - data:
      - zwave.somfy_unknown_type_5a52_id_5401
    service: cover.open_cover
- id: '1558531721963'
  alias: Outside Lights Sunset
  - event: sunset
    offset: -00:15:00
    platform: sun
  - condition: state
    entity_id: light.exterior_front_door
    state: 'off'
      - light.exterior_front_door
      - light.exterior_garage
      - light.exterior_inlaw_door
      - light.exterior_pool_stairs
    service: switch.turn_on
- id: '1558812661557'
  alias: Ventilation - Summer
  - at: '21:00:00'
    platform: time
  condition: []
  - data:
      entity_id: zwave.leviton_dzpa1_1lw_plug_in_appliance_module
    service: homeassistant.turn_on
  - delay: '12:00:00'
  - service: homeassistant.turn_off

Whenever you encounter an automation that looks like it should trigger but doesn’t, before doing any kind of deep analysis, do a quick sanity-check and confirm the automation is on and not off.

Go to the States page, locate the automation’s name, and confirm its state is on. If it’s off, you can either use the Services page to turn it on or in the Lovelace UI (probably listed in Unused Entities).

Thanks. All states are as expected. They are showing as off (lights, appliance module) and/or closed (blind)

I don’t know how to interpret your reply. For an automation, the “as expected” state should be on and not “showing as off”.

123 was talking about the state of the automation. not the other devices.

go to the states page and in the filter section type “automation.blind_schedule” and see what the state is. it should be ‘on’. if not turn it on as was suggested above.

Thanks for the clarification. Yes, the automations have a state of “on”

Every one of those automations is using either wrong entity_id or the wrong service in the actions:

you are using the wrong entity_id here. you never control any entity. That will always be the base device entity. You will need the entity that is associated with the device and use that.

you are trying to turn on lights using the service call for switches. That won’t work. You need to change the service to “light.turn_on”.

Same as the first one above. try to find a switch entity associated with the entity and use that. You can still use homeassistant.turn_on because that will turn on any domain but you could also use switch.turn_on if the entity you are controlling ends up being a entity.

1 Like

Thank you so much! My lighting and ventilation automations are working now. Still need to get the blinds to work … will try playing with it a bit more tomorrow.