Workaround for different GPS time & date string identifiers

This commit is contained in:
Hendrik Borras 2018-01-05 16:35:11 +01:00
parent 435d3fc20d
commit ead469fa1d

View file

@ -196,7 +196,8 @@ class CosmicPi_V15(detector, threading.Thread):
# check for GPS stings
gps_type = line_str.split(',')[0]
# check for a date string
if gps_type == "$GPZDA":
# ToDo: Make this an actual regular expression for "\$[A-Z][A-Z]ZDA"
if gps_type == "$GPZDA" or gps_type == "$GNZDA":
# sanity check
if not (line_str.count(',') == 6):
return False