diff --git a/selfdrive/car/gm/interface.py b/selfdrive/car/gm/interface.py index b20efba..b144aee 100644 --- a/selfdrive/car/gm/interface.py +++ b/selfdrive/car/gm/interface.py @@ -367,8 +367,14 @@ class CarInterface(CarInterfaceBase): if below_min_enable_speed and not (ret.standstill and ret.brake >= 20 and (self.CP.networkLocation == NetworkLocation.fwdCamera and not self.CP.carFingerprint in SDGM_CAR)): events.add(EventName.belowEngageSpeed) - if ret.cruiseState.standstill: + if ret.cruiseState.standstill and not self.disable_resumeRequired: events.add(EventName.resumeRequired) + self.resumeRequired_shown = True + + # Disable the "resumeRequired" event after it's been shown once to not annoy the driver + if self.resumeRequired_shown and not ret.cruiseState.standstill: + self.disable_resumeRequired = True + if ret.vEgo < self.CP.minSteerSpeed and not self.disable_belowSteerSpeed: events.add(EventName.belowSteerSpeed) self.belowSteerSpeed_shown = True diff --git a/selfdrive/car/interfaces.py b/selfdrive/car/interfaces.py index b423803..a5a42de 100644 --- a/selfdrive/car/interfaces.py +++ b/selfdrive/car/interfaces.py @@ -105,6 +105,9 @@ class CarInterfaceBase(ABC): self.belowSteerSpeed_shown = False self.disable_belowSteerSpeed = False + self.resumeRequired_shown = False + self.disable_resumeRequired = False + @staticmethod def get_pid_accel_limits(CP, current_speed, cruise_speed, frogpilot_variables): if frogpilot_variables.sport_plus: