ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
What's the need for fusing amcl
's output with odometry and IMU? I would think using amcl
alone would be pretty stable.
First of all, if you are ever having trouble, get rid of the advanced parameters. In this case, remove the rejection_threshold
parameters.
As for your questions:
When i use odom0_differential: true the filter output odometry_filtered/odom covariance grows quickly
That's what I'd expect to see. If you only fuse sources that are subject to drift, your covariance will grow without bound. What you typically see with a two-tier setup is that your odom-frame state estimate has an error that grows without bound (which is correct), and either amcl
or a second map-frame EKF produces a state estimate in the map frame that is _not_ subject to drift. See REP-105 for more details.
Regardless, if I were you, I'd stop fusing absolute pose from wheel odometry. Just fuse the velocities. differential
mode is meant for sensors that _only_ produce pose data. It differentiates subsequent poses and generates velocities from them. Your wheel encoders generate velocity data directly, so just fuse X velocity, Y velocity, and yaw velocity from your wheel encoders, and set X, Y, and yaw to false. You can then also remove the differential setting.
As far as your other issue goes, there are a couple things I see:
amcl
is the very node that is producing the map -> odom transform (I believe), when you fuse that measurement into the EKF, which is in the odom frame, you are effectively just feeding the EKF back its own pose as a measurement.amcl
. While you correctly turned on relative
mode for the IMU, I am wondering if the IMU's orientation is drifting. Magnetometers are notoriously terrible.In the end, the key takeaways are:
amcl
's pose as your estimate of where your robot is in the world. That can be used for global planning.