From 28f7f9d90939a807498f0c5426c62536bad6cdaa Mon Sep 17 00:00:00 2001 From: Jason Wen Date: Sat, 10 Dec 2022 16:10:54 -0500 Subject: [PATCH] Revert "Check DISTANCE_UNIT on CRUISE_BUTTONS" This reverts commit 9cbfe520f3406f8b1d66a56608a80417fea54871. --- selfdrive/car/hyundai/carstate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/selfdrive/car/hyundai/carstate.py b/selfdrive/car/hyundai/carstate.py index 5f53945836..bd6b72f461 100644 --- a/selfdrive/car/hyundai/carstate.py +++ b/selfdrive/car/hyundai/carstate.py @@ -200,7 +200,7 @@ class CarState(CarStateBase): ret.cruiseState.available = True cruise_btn_msg = "CRUISE_BUTTONS_ALT" if self.CP.flags & HyundaiFlags.CANFD_ALT_BUTTONS else "CRUISE_BUTTONS" - distance_unit_msg = cruise_btn_msg if self.CP.carFingerprint in (CAR.KIA_SORENTO_PHEV_4TH_GEN, CAR.IONIQ_5) else "CLUSTER_INFO" + distance_unit_msg = cruise_btn_msg if self.CP.carFingerprint == CAR.KIA_SORENTO_PHEV_4TH_GEN else "CLUSTER_INFO" self.is_metric = cp.vl[distance_unit_msg]["DISTANCE_UNIT"] != 1 if not self.CP.openpilotLongitudinalControl: speed_factor = CV.KPH_TO_MS if self.is_metric else CV.MPH_TO_MS