-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rivian: increase torque #2016
base: master
Are you sure you want to change the base?
Rivian: increase torque #2016
Conversation
d487a7a
to
b66d920
Compare
b66d920
to
53ec81a
Compare
Re-ran injection tests on the R1S to get a clearer picture at the torque drop off, pretty obvious now. It looks like it starts around 17 m/s (38 mph) and goes to 6.68 m/s (15 mph). Note that for the points at 5 m/s we couldn't maintain the max torque for very long as the wheel could reach 90 degrees which was the ACC disengagement threshold. https://connect.comma.ai/bc095dc92e101734/00000126--5176aa3ee8 |
Injection test with the latest interp on this PR: https://connect.comma.ai/bc095dc92e101734/0000012b--885dacf910 |
apply_torque = apply_driver_steer_torque_limits(new_torque, self.apply_torque_last, | ||
CS.out.steeringTorque, CarControllerParams) | ||
CS.out.steeringTorque, CarControllerParams, dynamic_steer_max) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: move this into apply_driver_steer_torque_limits
def get_steer_max(self, v_ego: float) -> int: | ||
return round(np.interp(v_ego, CarControllerParams.STEER_MAXES[0], CarControllerParams.STEER_MAXES[1])) | ||
|
||
# def torque_from_lateral_accel_rivian(self, latcontrol_inputs: LatControlInputs, torque_params: structs.CarParams.LateralTorqueTuning, | ||
# lateral_accel_error: float, lateral_accel_deadzone: float, friction_compensation: bool, gravity_adjusted: bool) -> float: | ||
# # The default is a linear relationship between torque and lateral acceleration (accounting for road roll and steering friction) | ||
# friction = get_friction(lateral_accel_error, lateral_accel_deadzone, FRICTION_THRESHOLD, torque_params, friction_compensation) | ||
# return (latcontrol_inputs.lateral_acceleration / float(torque_params.latAccelFactor)) + friction | ||
# | ||
# def torque_from_lateral_accel(self) -> TorqueFromLateralAccelCallbackType: | ||
# return self.torque_from_lateral_accel_rivian | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rm
2 things noticed from plotting torque points in 3D from torqued on this route:
2d2da5dea63b5c5e/00000011--fc863c57a2/q
But this goes against what we found in the lateral injection test. Perhaps higher torques become non-linear, need to plot more data.
rivian.3d.torque.mp4