Severe Weather Alerts from the US National Weather Service

I think this link should work:

nws_alert_tone.mp3

I also just remembered it’s at the github repo under the www folder there.

1 Like

I found a python script that can generate a SAME header and alert tone. I actually use the real data from the alert (3 letter event code, location codes for areas affected by alert polygon, start time, duration (message expiration), issuing authority or originating code, etc) to generate the header and tone on the fly and also the end of message tone. There’s actually two tones, the typical dual frequency (853Hz and 960Hz) heard over the radio and TV and then a single frequency at 1050Hz for weather radios.

It’s been a couple years since implementing this but I’ll see if I can find the library source again.

1 Like

@squirtbrnr That is awesome! If you can find that Python Library again, please do share! Thanks!

Sounds pretty cool.

Thanks!

I believe it is this one: GitHub - jmcmellen/sameeas: A Python script to generate AFSK data WAV files that can trigger NOAA Weather Radios and Emergency Alert System devices

I have more notes on my work laptop. Will add them when I find them.

Fun fact: that tone actually contains NWS Alert data :stuck_out_tongue:

EDIT: I guess I should read the rest of the thread before shotgun replying lol

And if crafted in a certain way and broadcast over certain radio frequencies using readily available consumer electronics, can cause a whole lot of confusion, panic, and possibly jail time or a hefty fine for the misuse of resources.

TV shows including but not limited to a couple late night talk show hosts have actually been fined by the FCC for using parts or all of an alert message and tone.

The EAS SAME header and tone is a powerful tool with a deep history dating back to the predecessor EBS (Emergency Broadcast System) and NOAA weather radios of the 1960s.

Then it’s a good thing I don’t send it out over anything than my own speakers. :grinning_face_with_smiling_eyes:

I had no idea.

I just downloaded an alert tone from some random mp3 website.

How would you know what data it contains?

I’ve used a program called “SeaTTY” (program has a free trial period, found here: Weather messages decoder - RTTY, NAVTEX, PACTOR-1 FEC, WEFAX (HF-FAX), NWR SAME software ) but you can open an audio clip that contains encoded data, tell it what kind of data and play it and it will decode the data. You can also connect an antenna through a sound card and decode real time transmissions too. The data is then broken into the EAS SAME header format which is pretty well documented.

EDIT: The message is a required monthly test on June 12th at 1016 local time for the counties surrounding WAVY-TV10 in Portsmouth, VA

it took me a while because I needed to convert that mp3 to a wav using audacity, then resample from a non-standard 24khz sample rate to 48khz. anyway, this is the data contained in the SAME header: ZCZC-CIV-RMT-051181-051700-051093-051199-051095-051830+0100-1641516-WAVYTV10

Decoded using the wikipedia article: Specific Area Message Encoding - Wikipedia

  • ZCZC - preamble to calibrate receivers and alert them of incoming message
  • CIV - originator authority - civil (governor, state/local police, etc)
  • RMT - event code - required monthly test event code
  • 051181-051700-051093-051199-051095-051830 - areas affected in PSSCCC format using “FIPS” code. P - 0 for entire county, SS - 51 for Virginia, CCC - 181, 700, 093, 199, 095, 830 for the following counties: Surry, Newport News, Isle of Wight, Washington, James City, Williamsburg
  • 0100 - purge time in HHMM when event ends
  • 1641516 - UTC time message was issued in JJJHHMM format. 164 ordinal day - June 13th (or June 12th if it was a leap year), 1516 UTC which is 1016 EST
  • WAVYTV10 - WAVY-TV 10 station in Portsmouth, VA is who broadcast the message
1 Like

Wow! That’s really interesting.

I’m not sure if it would be useful for the average joe (or jane) but it’s very interesting nonetheless.

Thanks for the detailed info.

To be honest, it’s not terribly useful unless you have the correct receiver (or weather radio that’s programmed with your specific County or area). All the message does is activate the weather radio or the broadcasting TV/radio stations EAS system which then gets transmitted to you. I just like to find hidden data in messages. You could potentially use it to trigger an automation if everything is correct (event code, affected area, time, etc) but at that point I’d rather just hook up a weather radio to the aux input of my Sonos amp and have Sonos automatically switch to that input when it detects audio then broadcast that through the house.

1 Like

Or just download an mp3 of the alert tone and play it instead. :wink:

Sounds very “007” ish.

:male_detective:

:grinning_face_with_smiling_eyes:

1 Like

Yep I do that too with Sonos and TTS and your weather alerts integration.

1 Like

Love this integration - thanks!

I was wondering if there is a solution to duplicate alerts caused by the “messageType” field being set to “Update” ?

It seems like update messages are intended to supersede existing ones (if you look at the NWS web site they only list the ‘update’ version), but the integration will display both (original+update) because the API lists them both.

What’s surprising is that the update messages don’t appear to contain any reference to the original message ID, so I’m not sure how you’re supposed to know which alert has been updated.

Thanks

I saw this video about the history of the tone, fines, etc

1 Like

Now I’m really starting to wonder if I should remove the sample tone from github… :grimacing:

:laughing:

I don’t see how if there is nothing that links the two alerts together.

TBH, I’ve never looked into it since duplicate messages don’t really concern me as long as the important ones come thru.

do you have an example of a location that currently has an update and original alert at the same time?

Did you see this? And they’re generously giving developers a whole month to fix it before it breaks on the next release :roll_eyes:

I’ve never seen such a short turn around time before making something not work.

Logger: homeassistant.helpers.frame
Source: helpers/frame.py:77
First occurred: 3:17:16 PM (1 occurrences)
Last logged: 3:17:16 PM

Detected integration that called async_setup_platforms instead of awaiting async_forward_entry_setups; this will fail in version 2023.3. Please report issue to the custom integration author for nws_alerts using this method at custom_components/nws_alerts/__init__.py, line 68: hass.config_entries.async_setup_platforms(entry, PLATFORMS)

Logic behind it is here I guess?

1 Like

I saw it and there was an issue posted on my github for it.

I think I’ve got a fix already but I’m testing it on my dev instance of HA now to make sure it’s working as expected.

thanks for the heads up tho.

I guess it was talked about in the developers blog at some point a while ago but unless you are a heavy developer I doubt anyone would see it there until it gets flagged for deprecation in someone’s log. I know I didn’t see it until now.

That’s good you have a fix on the way- I’m definitely a big fan of the integration and the work you’ve done on it.

Yours wasn’t the only one that generated this warning until I did other updates, so I doubt you’re the only one who missed it.

Whether the announcement is in the developer’s blog or in Alpha Centauri, they should at least give two versions warning before making any breaking change, well , break. I thought two versions was supposed to be the minimum anyway…

1 Like