mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-08-06 08:45:42 +08:00
fixed zss crashing lexus IS
This commit is contained in:
@@ -94,7 +94,11 @@ class CarState(CarStateBase):
|
||||
torque_sensor_angle_deg = cp.vl["STEER_TORQUE_SENSOR"]["STEER_ANGLE"]
|
||||
|
||||
# dp - zss controller
|
||||
ret.steeringAngleDeg = self.zssc.get_steering_angle_deg(cp.vl["PCM_CRUISE_2"]["MAIN_ON"], cp.vl["PCM_CRUISE"]["CRUISE_ACTIVE"], ret.steeringAngleDeg)
|
||||
if self.CP.carFingerprint in UNSUPPORTED_DSU_CAR:
|
||||
main_on = cp.vl["DSU_CRUISE"]["MAIN_ON"] != 0
|
||||
else:
|
||||
main_on = cp.vl["PCM_CRUISE_2"]["MAIN_ON"] != 0
|
||||
ret.steeringAngleDeg = self.zssc.get_steering_angle_deg(main_on, cp.vl["PCM_CRUISE"]["CRUISE_ACTIVE"], ret.steeringAngleDeg)
|
||||
|
||||
# On some cars, the angle measurement is non-zero while initializing
|
||||
if abs(torque_sensor_angle_deg) > 1e-3 and not bool(cp.vl["STEER_TORQUE_SENSOR"]["STEER_ANGLE_INITIALIZING"]):
|
||||
|
||||
Reference in New Issue
Block a user