I’m very new to Home Assistant. The good news is I purchased a R Pi 3B and setup HA with exactly zero problems. It was super-simple. The bad news is that I’m trying to setup a wemo to come on at sunset using the UI. All the documentation refers to editing files but I’m interested in just using the UI. Can someone walk me through this? I’m fine with the trigger, but specifically what “action” turns the switch on?
- alias: 'Automation Name'
trigger:
platform: sun
event: sunset
offset: "-00:30:00" # 30 minutes before sunset
action:
- service: switch.turn_on
entity_id: switch.wemo_name
You’ll need to do something similar to this, the GUI will need switch.turn_on as the action with the entity id
I’m running Sonoff basics and use the following trigger:
trigger:
platform: sun
event: sunset
Looks like gbboy beat me to it.
So:
Action type= “Call Service”
Service= “Switch.Turn_On”
Service Data="{entity_id: switch.front_outside_light}"
Is this correct?
I don’t use the interface but that looks correct. You can do a test by changing the trigger from sunset to time and making sure it turns on.
yeah, this doesn’t work… I’m lost with this thing as there is zero documentation on the GUI.
Just for the record, I tried openhab and ran into the exact same problem. They have a nice slick GUI with no documentation what so ever. Unfortunate.
I have one that turns a light on before sunset…
Under Trigger:
Trigger Type: State
Entity: mine says light.lounge but my wemo automation does not have this section…
I then have a second trigger:
Trigger Type: sun
Event: Sunset
Offset: -01:50:00
Then under Action:
Action Type: Call Service
Service: light.turn_on (you would have switch.turn_on)
Service Data: {“entity_id”:“switch.wemo”} - note you need to check the actual entity ID in services.
If you click on the <> symbol, it will give you a list of entity ID’s.
Also if you then go to services, the icon to the left of <> you can select the service - say switch.turn_on, select the entity from the dropdown and call the service to see if it triggers.
Also be aware there was a bug in recent versions of Hass that the automation GUI didn’t display correctly. It seems find in 0.60.1 if you are running that.
Thank you, this is now working. I was just missing the quotes in the service data entry…
{“entity_id”:“switch.wemo”}