diff --git a/includes/decoders/fms.py b/includes/decoders/fms.py index b7d77d6..af85b70 100644 --- a/includes/decoders/fms.py +++ b/includes/decoders/fms.py @@ -44,16 +44,13 @@ def decode(freq, decoded): fms_directionText = decoded[103:110] # Richtung (Text) fms_tsi = decoded[114:117] # Taktische Kruzinformation + proceec = True # no CRC-check required - proceed + # shall we use the CRC-check? if (globalVars.config.getboolean("FMS", "CheckCRC")): - if "CRC correct" in decoded: - # if CRC is to be checked, do so and save result - proceed = True - else: + if "CRC correct" not in decoded: + # if CRC must be checked and is not correct - dont proceed proceed = False - else: - # no CRC-check required - proceed - proceed = True if (proceed == True): fms_id = fms_service+fms_country+fms_location+fms_vehicle+fms_status+fms_direction # build FMS id diff --git a/includes/helper/wildcardHandler.py b/includes/helper/wildcardHandler.py index 358f4b6..d67dde2 100644 --- a/includes/helper/wildcardHandler.py +++ b/includes/helper/wildcardHandler.py @@ -53,7 +53,7 @@ def replaceWildcards(text, data, lineBrakeAllowed=False): # replace POC data if "ric" in data: text = text.replace("%RIC%", data["ric"]) - if "function" in data: + if "function" in data: text = text.replace("%FUNC%", data["function"]) if data["function"] == "1": text = text.replace("%FUNCTEXT%", globalVars.config.get("POC","rica")) if data["function"] == "2": text = text.replace("%FUNCTEXT%", globalVars.config.get("POC","ricb"))