This commit is contained in:
Jason Wen
2024-08-13 01:19:10 -04:00
parent b9d3816fbe
commit d7f502f4ea
+2 -3
View File
@@ -646,10 +646,9 @@ class Controls:
if not self.joystick_mode:
speeds = long_plan.speeds
a_lead = self.sm['radarState'].leadOne.aLeadK
resume = self.enabled_long and CS.standstill and self.CP.carName == "hyundai"
resume = False
if len(speeds):
resume = resume and speeds[-1] > 0.1
resume = resume and a_lead > 0.1
resume = self.enabled_long and CS.standstill and self.CP.carName == "hyundai" and speeds[-1] > 0.1 and a_lead > 0.1
# accel PID loop
pid_accel_limits = self.CI.get_pid_accel_limits(self.CP, CS.vEgo, self.v_cruise_helper.v_cruise_kph * CV.KPH_TO_MS)