Tesla: steerWarning on EPS error (#22834)

old-commit-hash: fee8ec74f1
commatwo_master
Robbe Derks 4 years ago committed by GitHub
parent f30f550f84
commit 149267c031
  1. 2
      selfdrive/car/tesla/carstate.py

@ -43,7 +43,7 @@ class CarState(CarStateBase):
ret.steeringTorque = -cp.vl["EPAS_sysStatus"]["EPAS_torsionBarTorque"]
ret.steeringPressed = (self.hands_on_level > 0)
ret.steerError = steer_status == "EAC_FAULT"
ret.steerWarning = self.steer_warning in ["EAC_ERROR_MAX_SPEED", "EAC_ERROR_MIN_SPEED", "EAC_ERROR_TMP_FAULT", "SNA"] # TODO: not sure if this list is complete
ret.steerWarning = self.steer_warning != "EAC_ERROR_IDLE"
# Cruise state
cruise_state = self.can_define.dv["DI_state"]["DI_cruiseState"].get(int(cp.vl["DI_state"]["DI_cruiseState"]), None)

Loading…
Cancel
Save