diff --git a/selfdrive/car/toyota/carcontroller.py b/selfdrive/car/toyota/carcontroller.py index 4ae80a7796..dc9d8608af 100644 --- a/selfdrive/car/toyota/carcontroller.py +++ b/selfdrive/car/toyota/carcontroller.py @@ -142,7 +142,7 @@ class CarController(CarControllerBase): # Press distance button until we are at the correct bar length. Only change while enabled to avoid skipping startup popup if self.frame % 6 == 0: - desired_distance = 4 - hud_control.distanceBars + desired_distance = 4 - hud_control.leadDistanceBars if CS.pcm_follow_distance != desired_distance and CS.out.cruiseState.enabled and self.CP.carFingerprint not in UNSUPPORTED_DSU_CAR: self.distance_button = not self.distance_button else: diff --git a/selfdrive/car/toyota/carstate.py b/selfdrive/car/toyota/carstate.py index 65fced80f4..5d99467f25 100644 --- a/selfdrive/car/toyota/carstate.py +++ b/selfdrive/car/toyota/carstate.py @@ -44,7 +44,6 @@ class CarState(CarStateBase): self.distance_button = 0 self.pcm_follow_distance = 0 - self.pcm_follow_distance_values = can_define.dv['PCM_CRUISE_2']['PCM_FOLLOW_DISTANCE'] self.low_speed_lockout = False self.acc_type = 1 diff --git a/selfdrive/controls/controlsd.py b/selfdrive/controls/controlsd.py index c18b0dfeda..29358cb7b6 100755 --- a/selfdrive/controls/controlsd.py +++ b/selfdrive/controls/controlsd.py @@ -680,7 +680,7 @@ class Controls: hudControl.speedVisible = self.enabled hudControl.lanesVisible = self.enabled hudControl.leadVisible = self.sm['longitudinalPlan'].hasLead - hudControl.distanceBars = self.sm['longitudinalPlan'].personality.raw + 1 + hudControl.leadDistanceBars = self.sm['longitudinalPlan'].personality.raw + 1 hudControl.rightLaneVisible = True hudControl.leftLaneVisible = True