From 1c566f7ef15062e95e2f9f2d5cbfaeb4fff530ec Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Fri, 21 Oct 2022 12:27:21 -0700 Subject: [PATCH] fine if we skip, we usually send too early --- selfdrive/car/gm/carcontroller.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/selfdrive/car/gm/carcontroller.py b/selfdrive/car/gm/carcontroller.py index 9ab2752fcc..a26bb4e96e 100644 --- a/selfdrive/car/gm/carcontroller.py +++ b/selfdrive/car/gm/carcontroller.py @@ -51,7 +51,7 @@ class CarController: # TODO: ENSURE this logic works if we lag right as we switch from 50hz to 10hz, will they be too far apart? self.lka_steering_cmd_counter += 1 self.sent_lka_steering_cmd = True - elif (self.frame - self.last_steer_frame) >= steer_step or self.last_steer_frame == 0: + elif (self.frame - self.last_steer_frame) >= steer_step: # Initialize ASCMLKASteeringCmd counter using the camera if not self.sent_lka_steering_cmd and self.CP.networkLocation == NetworkLocation.fwdCamera: self.lka_steering_cmd_counter = CS.camera_lka_steering_cmd_counter + 1