diff --git a/config.template b/config.template index 46c64a4..df7660e 100644 --- a/config.template +++ b/config.template @@ -203,15 +203,15 @@ useMetric = False # repeaterList lookup location (rbook / artsci / False) repeaterLookup = rbook -# use Open-Meteo API for weather data not NOAA useful for non US locations -UseMeteoWxAPI = False - # Satalite Pass Prediction # Register for free API https://www.n2yo.com/login/ personal data page at bottom 'Are you developer?' n2yoAPIKey = # NORAD list https://www.n2yo.com/satellites/ satList = 25544,7530 +# use Open-Meteo API for weather data not NOAA useful for non US locations +UseMeteoWxAPI = False + # NOAA weather forecast days NOAAforecastDuration = 3 # number of weather alerts to display @@ -261,6 +261,9 @@ enableDEalerts = False # find your regional codet at https://www.xrepository.de/api/xrepository/urn:de:bund:destatis:bevoelkerungsstatistik:schluessel:rs_2021-07-31/download/Regionalschl_ssel_2021-07-31.json myRegionalKeysDE = 110000000000,120510000000 +# Alerts are sent to the emergency_handler interface and channel duplicate messages are send here if set +eAlertBroadcastCh = + # CheckList Checkin/Checkout [checklist] enabled = False diff --git a/modules/settings.py b/modules/settings.py index aa894b8..9251cec 100644 --- a/modules/settings.py +++ b/modules/settings.py @@ -339,6 +339,7 @@ try: myStateFIPSList = config['location'].get('myFIPSList', '').split(',') # default empty mySAMEList = config['location'].get('mySAMEList', '').split(',') # default empty myRegionalKeysDE = config['location'].get('myRegionalKeysDE', '110000000000').split(',') # default city Berlin + eAlertBroadcastChannel = config['location'].getint('eAlertBroadcastChannel', '') # default empty # any alert broadcast enabled anyAlertBroadcastEnabled = ( diff --git a/modules/system.py b/modules/system.py index 3be0fe7..e66e434 100644 --- a/modules/system.py +++ b/modules/system.py @@ -1172,7 +1172,9 @@ def handleAlertBroadcast(deviceID=1): for alert_type, alert_msg, enabled in alert_types: if enabled and alert_msg and NO_ALERTS not in alert_msg and ERROR_FETCHING_DATA not in alert_msg: if should_send_alert(alert_type, alert_msg): - send_message(alert_msg, emergency_responder_alert_channel, 0, deviceID) + send_message(alert_msg, emergency_responder_alert_channel, 0, emergency_responder_alert_interface) + if eAlertBroadcastChannel != '': + send_message(alert_msg, eAlertBroadcastChannel, 0, emergency_responder_alert_interface) except Exception as e: logger.error(f"System: Error in handleAlertBroadcast: {e}") return False