From d3058de5c1881a0d9eac3badbabc093d2d58a285 Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Sat, 1 Aug 2026 06:26:31 -0700 Subject: [PATCH] ldw: fix blinker cooldown using wrong time step (#38501) Co-authored-by: Shane Smiskol --- openpilot/selfdrive/controls/lib/ldw.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openpilot/selfdrive/controls/lib/ldw.py b/openpilot/selfdrive/controls/lib/ldw.py index 6db59791cc..6164111190 100644 --- a/openpilot/selfdrive/controls/lib/ldw.py +++ b/openpilot/selfdrive/controls/lib/ldw.py @@ -1,5 +1,5 @@ from openpilot.cereal import log -from openpilot.common.realtime import DT_CTRL +from openpilot.common.realtime import DT_MDL from openpilot.common.constants import CV @@ -17,7 +17,7 @@ class LaneDepartureWarning: if CS.leftBlinker or CS.rightBlinker: self.last_blinker_frame = frame - recent_blinker = (frame - self.last_blinker_frame) * DT_CTRL < 5.0 # 5s blinker cooldown + recent_blinker = (frame - self.last_blinker_frame) * DT_MDL < 5.0 # 5s blinker cooldown ldw_allowed = CS.vEgo > LDW_MIN_SPEED and not recent_blinker and not CC.latActive desire_prediction = modelV2.meta.desirePrediction