mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-18 22:23:56 +08:00
paramsd: Remove one active condition (#26922)
* remove one active condition * update refs * remove unused vars * update refs * update refs
This commit is contained in:
@@ -36,7 +36,6 @@ class ParamsLearner:
|
||||
self.yaw_rate = 0.0
|
||||
self.yaw_rate_std = 0.0
|
||||
self.roll = 0.0
|
||||
self.steering_pressed = False
|
||||
self.steering_angle = 0.0
|
||||
|
||||
self.valid = True
|
||||
@@ -88,10 +87,9 @@ class ParamsLearner:
|
||||
|
||||
elif which == 'carState':
|
||||
self.steering_angle = msg.steeringAngleDeg
|
||||
self.steering_pressed = msg.steeringPressed
|
||||
self.speed = msg.vEgo
|
||||
|
||||
in_linear_region = abs(self.steering_angle) < 45 or not self.steering_pressed
|
||||
in_linear_region = abs(self.steering_angle) < 45
|
||||
self.active = self.speed > 1 and in_linear_region
|
||||
|
||||
if self.active:
|
||||
|
||||
@@ -1 +1 @@
|
||||
e41c3dd90cf61d0a630ba53c7e866cb2be3fc1a8
|
||||
c714ab010923f2bce732bd22e903ccc4454136fd
|
||||
Reference in New Issue
Block a user