Update interface.py

This commit is contained in:
firestar5683
2025-05-11 00:35:23 -05:00
parent 5b416be265
commit 7157ccc607
+16 -3
View File
@@ -147,7 +147,12 @@ class CarInterface(CarInterfaceBase):
ret.safetyConfigs[0].safetyParam |= Panda.FLAG_GM_HW_SDGM
else: # ASCM, OBD-II harness
ret.openpilotLongitudinalControl = not frogpilot_toggles.disable_openpilot_long
try:
disable_long = frogpilot_toggles.disable_openpilot_long
except AttributeError:
disable_long = params.get_bool("DisableOpenpilotLongitudinal")
ret.openpilotLongitudinalControl = not disable_long
ret.networkLocation = NetworkLocation.gateway
ret.radarUnavailable = RADAR_HEADER_MSG not in fingerprint[CanBus.OBSTACLE] and not docs
ret.pcmCruise = False # stock non-adaptive cruise control is kept off
@@ -269,7 +274,11 @@ class CarInterface(CarInterfaceBase):
ret.safetyConfigs[0].safetyParam |= Panda.FLAG_GM_HW_CAM
ret.minEnableSpeed = -1
ret.pcmCruise = False
ret.openpilotLongitudinalControl = not frogpilot_toggles.disable_openpilot_long
try:
disable_long = frogpilot_toggles.disable_openpilot_long
except AttributeError:
disable_long = params.get_bool("DisableOpenpilotLongitudinal")
ret.openpilotLongitudinalControl = not disable_long
ret.stoppingControl = True
ret.autoResumeSng = True
@@ -293,7 +302,11 @@ class CarInterface(CarInterfaceBase):
ret.radarUnavailable = True
ret.experimentalLongitudinalAvailable = False
ret.minEnableSpeed = 24 * CV.MPH_TO_MS
ret.openpilotLongitudinalControl = not frogpilot_toggles.disable_openpilot_long
try:
disable_long = frogpilot_toggles.disable_openpilot_long
except AttributeError:
disable_long = params.get_bool("DisableOpenpilotLongitudinal")
ret.openpilotLongitudinalControl = not disable_long
ret.pcmCruise = False
if not ret.enableGasInterceptor and candidate in CC_ONLY_CAR: #redneck tuning