live torque params

This commit is contained in:
MoreTore
2025-05-12 22:59:48 -05:00
parent 840dacd700
commit 3e1d13c70b
2 changed files with 5 additions and 3 deletions
+4 -2
View File
@@ -32,7 +32,8 @@ MIN_BUCKET_POINTS = np.array([100, 300, 500, 500, 500, 500, 300, 100])
MIN_ENGAGE_BUFFER = 2 # secs
VERSION = 1 # bump this to invalidate old parameter caches
ALLOWED_CARS = ['toyota', 'hyundai', 'rivian']
ALLOWED_BRANDS = ['toyota', 'hyundai', 'rivian']
ALLOWED_CARS = ['MAZDA_3_2019']
def slope2rot(slope):
@@ -71,7 +72,8 @@ class TorqueEstimator(ParameterEstimator):
self.offline_friction = 0.0
self.offline_latAccelFactor = 0.0
self.resets = 0.0
self.use_params = CP.brand in ALLOWED_CARS and CP.lateralTuning.which() == 'torque'
self.use_params = CP.brand in ALLOWED_BRANDS and CP.lateralTuning.which() == 'torque'
self.use_params |= CP.carFingerprint in ALLOWED_CARS
if CP.lateralTuning.which() == 'torque':
self.offline_friction = CP.lateralTuning.torque.friction