Quiet steer temp unavailable alert at standstill (#22680)

* only sound critical alert when not at standstill

* need to flip

* just change the one line
pull/22690/head^2
sshane 4 years ago committed by GitHub
parent b950bc2c17
commit 82ad6642e2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      selfdrive/car/interfaces.py

@ -144,7 +144,8 @@ class CarInterfaceBase():
elif cs_out.steerWarning:
# only escalate to the harsher alert after the condition has
# persisted for 0.5s and we're certain that the user isn't overriding
if self.steering_unpressed > int(0.5/DT_CTRL) and self.steer_warning > int(0.5/DT_CTRL):
if not cs_out.standstill and self.steering_unpressed > int(0.5 / DT_CTRL) and \
self.steer_warning > int(0.5 / DT_CTRL):
events.add(EventName.steerTempUnavailable)
else:
events.add(EventName.steerTempUnavailableSilent)

Loading…
Cancel
Save