From c5a85ba83152e07a182534f86cdf385ea45db87f Mon Sep 17 00:00:00 2001 From: Jason Wen Date: Sat, 23 Sep 2023 05:18:36 -0400 Subject: [PATCH] Gap Adjust Cruise: Fix object reference --- selfdrive/car/toyota/interface.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/selfdrive/car/toyota/interface.py b/selfdrive/car/toyota/interface.py index 3a24cdd623..54f6c7b206 100644 --- a/selfdrive/car/toyota/interface.py +++ b/selfdrive/car/toyota/interface.py @@ -324,8 +324,8 @@ class CarInterface(CarInterfaceBase): self.CS.madsEnabled = self.get_acc_mads(ret.cruiseState.enabled, self.CS.accEnabled, self.CS.madsEnabled) if not self.CP.openpilotLongitudinalControl: self.CS.gac_tr_cluster = 3 - if CS.gac_tr != 2: - CS.gac_tr = 2 + if self.CS.gac_tr != 2: + self.CS.gac_tr = 2 put_nonblocking("LongitudinalPersonality", "2") else: gap_dist_button = bool(self.CS.gap_dist_button)