mirror of
https://github.com/projecthorus/sondehub-infra.git
synced 2025-02-20 17:12:50 +00:00
Add MTS01, wrap vaisala check
This commit is contained in:
parent
a8ad0bffd0
commit
3ef8c21e2d
@ -190,7 +190,10 @@ def telemetry_filter(telemetry):
|
||||
# ~2025-2030, so have expanded the regex to match (and also support some older RS92s)
|
||||
# Modified 2021-06 to be more flexible and match older sondes, and reprogrammed sondes.
|
||||
# Still needs a letter at the start, but the numbers don't need to match the format exactly.
|
||||
vaisala_callsign_valid = re.match(r"[C-Z][\d][\d][\d]\d{4}", _serial)
|
||||
if ("RS41" in telemetry["type"]) or ("RS92" in telemetry["type"]):
|
||||
vaisala_callsign_valid = re.match(r"[C-Z][\d][\d][\d]\d{4}", _serial)
|
||||
else:
|
||||
vaisala_callsign_valid = False
|
||||
|
||||
# Just make sure we're not getting the 'xxxxxxxx' unknown serial from the DFM decoder.
|
||||
if "DFM" in telemetry["type"]:
|
||||
@ -220,8 +223,10 @@ def telemetry_filter(telemetry):
|
||||
or ("M20" in telemetry["type"])
|
||||
or ("LMS" in telemetry["type"])
|
||||
or ("iMet" in telemetry["type"])
|
||||
or ("MRZ" in telemetry["type"])
|
||||
or ("MTS01" in telemetry["type"])
|
||||
):
|
||||
_id_msg = "Payload ID %s is invalid." % telemetry["serial"]
|
||||
_id_msg = "Payload ID %s from Sonde type %s is invalid." % (telemetry["serial"], telemetry["type"])
|
||||
# Add in a note about DFM sondes and their oddness...
|
||||
if "DFM" in telemetry["serial"]:
|
||||
_id_msg += " Note: DFM sondes may take a while to get an ID."
|
||||
|
Loading…
x
Reference in New Issue
Block a user