I am trying to figure out if it is possible to have a severe weather event trigger a light to start flashing, and then the user can turn off the light after acknowledging the alert.
I have the severe weather alert already setup as a sensor in hassio that gives the user an indication of how many alerts are active.
I’m quite a noobie, but I suppose you could create a recursive automation that is triggered by the severe weather sensor, toggles the light and calls itself. It will have a boolean condition that is toggled by the physical light switch and inhibit the automation. Once it’s inhibited, it won’t call itself within a certain period of time (a day, for instance)
Please format code using the </> button. Are you sure you mean zones and not areas? Looking at the data at that URL, the zones are more specific, and the state counts are in areas.
You could set up an automation to turn your flashing light on based on changes to the value of your sensor, and another one to switch it off based on notification dismissal, but you’d need to decide how you want it to trigger:
@finity Sorry to bring up an old post, but I’m having an issue getting NWS alerts started. I download from hacs, but never get the integration to show up after that. I went ahead and added the sensor, shows up in dev. tools. Then I get state “0” and attribution: Data provided by Weather.gov title: null event_id: null message_type: null event_status: null display_desc: null spoken_desc: null icon: mdi:alert friendly_name: NWS Alerts
Any idea where this is going wrong? I’ve tried downloading, removing, downloading, clearing cache.
you can go to “https://api.weather.gov/alerts/active/count” and look for your zone info in the list. If your zone isn’t in the list then you have no active alerts and what you are seeing is normal.
Excellent, thanks for integration! Exactly what I was hoping to find. Sorry to drag up this post, but thought it was appropriate place.
Do you know, or know where I can find the list of values for the sensor attributes? Specifically Event Severity? I really only wanted to monitor for severe warning alerts.
Scrolled your yaml and found a couple values. Didn’t want to wait for the severe warnings to find out I missed one.
Thanks!
That attribute was added a while after my initial implementation as a request from another user. I don’t think I even use that attribute anywhere in my config.
I just use the alert types which are pretty well documented:
Interesting…you mean the single quotes like this '' ?
This automation went off just fine recently (5 times in one night), but I’m still learning and understand some of these things work today, but might not tomorrow.