From 1966845fc9213f332e566a954c6d015ee05920c1 Mon Sep 17 00:00:00 2001 From: DevTekVE Date: Sat, 2 Aug 2025 00:17:37 +0200 Subject: [PATCH] refactor: move lateral methods from init to lateral.py (#35856) * refactor: move lateral methods from init to lateral.py (#2594) * Extracting lateral methods to lateral.py * cleaning * more cleaning * more cleaning * Making sure it remains where it should * Leave rate_limit where it belongs * Moving things to `car/controls/` * Moving rate limit to get a taste of the changes * clean * copy verbatim * clean up * more * now we can format --------- Co-authored-by: Shane Smiskol * No need to change order of import --------- Co-authored-by: Shane Smiskol Co-authored-by: Adeeb Shihadeh --- opendbc_repo | 2 +- selfdrive/controls/lib/latcontrol_torque.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/opendbc_repo b/opendbc_repo index 8758063032..a517b9973a 160000 --- a/opendbc_repo +++ b/opendbc_repo @@ -1 +1 @@ -Subproject commit 875806303223d2d6e38451213a0febfc6801b652 +Subproject commit a517b9973ab1e03e0c13770ec3bd5849ede4202d diff --git a/selfdrive/controls/lib/latcontrol_torque.py b/selfdrive/controls/lib/latcontrol_torque.py index fc704ad1dc..b04f489749 100644 --- a/selfdrive/controls/lib/latcontrol_torque.py +++ b/selfdrive/controls/lib/latcontrol_torque.py @@ -2,7 +2,7 @@ import math import numpy as np from cereal import log -from opendbc.car import FRICTION_THRESHOLD, get_friction +from opendbc.car.lateral import FRICTION_THRESHOLD, get_friction from opendbc.car.interfaces import LatControlInputs from opendbc.car.vehicle_model import ACCELERATION_DUE_TO_GRAVITY from openpilot.selfdrive.controls.lib.latcontrol import LatControl