qiayuanl / legged_control

Nonlinear MPC and WBC framework for legged robot based on OCS2 and ros-controls
BSD 3-Clause "New" or "Revised" License
854 stars 217 forks source link

There is a gap between the positions of gazebo and rviz #20

Closed liukaishu closed 1 year ago

liukaishu commented 1 year ago

Hello, when I run your program and walk for a while, the position of the robot in gazebo and rviz is inconsistent, that is, the spatial position is not uniform, and there is a certain error. May I ask what is the reason and how to solve it?

qiayuanl commented 1 year ago

Hi, this is because the errors of the odometery (a linear Kalman filter that estimates the base position and velocity from base orientation, base acceleration, and joint foot position measurements.)

If you want to use the ground truth, try LeggedCheaterController. NOTE that you shouldn't use this controller in real robot!