Skip to content

Commit

Permalink
updating forward_kinematics.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
nakul-py committed Jan 8, 2025
1 parent 8791513 commit 8f61d10
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions steering_controllers_library/src/forward_kinematics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ struct Odometry {
};

Odometry ForwardKinematics::calculate(double linear_velocity, double angular_velocity) {
// Implement your forward kinematics calculation logic here
// Example placeholder calculation

Odometry odom_result;
odom_result.x = linear_velocity * params_.wheel_base; // Replace with correct formula
odom_result.y = 0.0; // Adjust if side motion is modeled
odom_result.theta = angular_velocity; // Adjust if needed
odom_result.x = linear_velocity * params_.wheel_base;
odom_result.y = 0.0;
odom_result.theta = angular_velocity;

return odom_result;
}

0 comments on commit 8f61d10

Please sign in to comment.