From 4bbeb27f9b56676483776920a62ecb135a2880ed Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Fri, 29 Oct 2021 13:07:52 -0700 Subject: [PATCH] Mazda: allow engaging below min LKAS speed (#22737) * Mazda: allow engagement below minimum LKAS speed * bump panda * bump panda --- panda | 2 +- selfdrive/car/mazda/carstate.py | 9 ++------- selfdrive/car/mazda/interface.py | 3 --- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/panda b/panda index 06ec4331f..0d4e98f60 160000 --- a/panda +++ b/panda @@ -1 +1 @@ -Subproject commit 06ec4331f4e18faf30562ca5dfcfca2ae082d912 +Subproject commit 0d4e98f6056a69da8933c8a690a803bc96e0e528 diff --git a/selfdrive/car/mazda/carstate.py b/selfdrive/car/mazda/carstate.py index 2c8cc9f01..b5ab645fb 100644 --- a/selfdrive/car/mazda/carstate.py +++ b/selfdrive/car/mazda/carstate.py @@ -14,7 +14,6 @@ class CarState(CarStateBase): self.cruise_speed = 0 self.acc_active_last = False - self.low_speed_lockout = True self.low_speed_alert = False self.lkas_allowed = False @@ -69,13 +68,9 @@ class CarState(CarStateBase): ret.cruiseState.speed = cp.vl["CRZ_EVENTS"]["CRZ_SPEED"] * CV.KPH_TO_MS if ret.cruiseState.enabled: - if not self.lkas_allowed: - if not self.acc_active_last: - self.low_speed_lockout = True - else: - self.low_speed_alert = True + if not self.lkas_allowed and self.acc_active_last: + self.low_speed_alert = True else: - self.low_speed_lockout = False self.low_speed_alert = False # Check if LKAS is disabled due to lack of driver torque when all other states indicate diff --git a/selfdrive/car/mazda/interface.py b/selfdrive/car/mazda/interface.py index 5472a0297..db9872eea 100755 --- a/selfdrive/car/mazda/interface.py +++ b/selfdrive/car/mazda/interface.py @@ -86,9 +86,6 @@ class CarInterface(CarInterfaceBase): # events events = self.create_common_events(ret) - if self.CS.low_speed_lockout: - events.add(EventName.belowEngageSpeed) - if self.CS.low_speed_alert: events.add(EventName.belowSteerSpeed)