From c6bcd93d6c7a3f1c8541d5b062cbfcc0f7ebc5d3 Mon Sep 17 00:00:00 2001 From: royjr Date: Tue, 13 Dec 2022 11:48:49 -0500 Subject: [PATCH] fix speed mismatch and standstill --- selfdrive/car/honda/carcontroller.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/selfdrive/car/honda/carcontroller.py b/selfdrive/car/honda/carcontroller.py index 790dce1810..04b98e6f9a 100644 --- a/selfdrive/car/honda/carcontroller.py +++ b/selfdrive/car/honda/carcontroller.py @@ -127,7 +127,18 @@ class CarController: def update(self, CC, CS): actuators = CC.actuators hud_control = CC.hudControl - hud_v_cruise = hud_control.setSpeed * CV.MS_TO_KPH if hud_control.speedVisible else 255 + + if self.CP.carFingerprint in HONDA_BOSCH_RADARLESS: + stopping = actuators.longControlState == LongCtrlState.stopping + if CC.longActive and stopping: + hud_v_cruise = 252 + else: + if CS.is_metric: + hud_v_cruise = hud_control.setSpeed * CV.MS_TO_KPH if hud_control.speedVisible else 255 + else: + hud_v_cruise = hud_control.setSpeed * CV.MS_TO_MPH if hud_control.speedVisible else 255 + else: + hud_v_cruise = hud_control.setSpeed * CV.MS_TO_MPH if hud_control.speedVisible else 255 pcm_cancel_cmd = CC.cruiseControl.cancel if CC.longActive: