diff --git a/apk/ai.comma.plus.offroad.apk b/apk/ai.comma.plus.offroad.apk index c221675d7..d990c55f9 100644 Binary files a/apk/ai.comma.plus.offroad.apk and b/apk/ai.comma.plus.offroad.apk differ diff --git a/common/params.py b/common/params.py index f6c5b19cb..c1faa903f 100755 --- a/common/params.py +++ b/common/params.py @@ -94,10 +94,10 @@ keys = { "DragonDisableUploader": [TxType.PERSISTENT], # deprecated "DragonEnableUploader": [TxType.PERSISTENT], "DragonNoctuaMode": [TxType.PERSISTENT], - "DragonCacheCar": [TxType.PERSISTENT], - "DragonCachedModel": [TxType.PERSISTENT], - "DragonCachedFP": [TxType.PERSISTENT], - "DragonCachedVIN": [TxType.PERSISTENT], + "DragonCacheCar": [TxType.PERSISTENT], # deprecated + "DragonCachedModel": [TxType.PERSISTENT], # deprecated + "DragonCachedFP": [TxType.PERSISTENT], # deprecated + "DragonCachedVIN": [TxType.PERSISTENT], # deprecated "DragonAllowGas": [TxType.PERSISTENT], "DragonBBUI": [TxType.PERSISTENT], "DragonToyotaStockDSU": [TxType.PERSISTENT], diff --git a/selfdrive/dragonpilot/dragonconf/__init__.py b/selfdrive/dragonpilot/dragonconf/__init__.py index 8adcc72cd..7757d516c 100644 --- a/selfdrive/dragonpilot/dragonconf/__init__.py +++ b/selfdrive/dragonpilot/dragonconf/__init__.py @@ -18,10 +18,10 @@ default_conf = { 'DragonDisableUploader': '0', # deprecated 'DragonEnableUploader': '1', 'DragonNoctuaMode': '0', - 'DragonCacheCar': '1', - 'DragonCachedModel': '', # for cache car - 'DragonCachedFP': '', # for cache car - 'DragonCachedVIN': '', # for cache car + 'DragonCacheCar': '1', # deprecated + 'DragonCachedModel': '', # for cache car # deprecated + 'DragonCachedFP': '', # for cache car # deprecated + 'DragonCachedVIN': '', # for cache car # deprecated 'DragonAllowGas': '0', 'DragonBBUI': '0', 'DragonToyotaStockDSU': '0', @@ -32,6 +32,10 @@ deprecated_conf = { 'DragonTempDisableSteerOnSignal': 'DragonEnableSteeringOnSignal', 'DragonDisableLogger': 'DragonEnableLogger', 'DragonDisableUploader': 'DragonEnableUploader', + 'DragonCacheCar': None, + 'DragonCachedModel': None, + 'DragonCachedFP': None, + 'DragonCachedVIN': None, } deprecated_conf_invert = { @@ -45,12 +49,13 @@ def dragonpilot_set_params(params): # remove deprecated params for old, new in deprecated_conf.items(): if params.get(old) is not None: - old_val = str(params.get(old)) - new_val = old_val - # invert the value if true - if old in deprecated_conf_invert and deprecated_conf_invert[old] is True: - new_val = "1" if old_val == "0" else "0" - params.put(new, new_val) + if new is not None: + old_val = str(params.get(old)) + new_val = old_val + # invert the value if true + if old in deprecated_conf_invert and deprecated_conf_invert[old] is True: + new_val = "1" if old_val == "0" else "0" + params.put(new, new_val) params.delete(old) # set params