How to calculate the actuator position on the controller interface of the simulation package

asked 2020-11-27 01:04:42 -0600

harderthan gravatar image

Hello. I'm trying to study vehicle kinematics with autoware simulation package.
I don't understand the code well.

On the code (in void VehicleGazeboInputSubscriber::twistCallback()). There are some lines for calculating steering position. = std::atan(std::tan(delta_ref) / (1.0 + (wheel_tread_ / (2.0 * wheel_base_)) * std::tan(delta_ref))); = std::atan(std::tan(delta_ref) / (1.0 - (wheel_tread_ / (2.0 * wheel_base_)) * std::tan(delta_ref)));

Below are what I understood.

output_steering_right_front is a variable for steering_right_front_position_controller.
If it increases or decreases, it will push or pull the wheel which attached on the joint of it.
So, it should be calculated how much handle the steering to turn our robot body.
Given max_delta_ref (deltha) variable and vref_rear (linear velocity) variable, how to calculate the position of steering link?

Could you explain the formula represented by "std::atan(std::tan(delta_ref) / (1.0 + (wheel_tread_ / (2.0 * wheel_base_)) * std::tan(delta_ref)))" ?

edit retag flag offensive close merge delete