robot_localization wrong output
I am trying to use an ekf_localization_node to fuse two sensors, odometry and pose, with the package robot_localization, in two dimensions. However, the output (published in the topic /odometry/filtered) seems to be wrong, since it is constantly moving and rotating even when the robot is still. Moreover, the odometry is always 0 without error, because I am using rqt_publisher to manually publish the topic /example/odom.
When I move the robot, the output follows that move, but when the robot doesn't move anymore, the output continues with that last movement. For example, if I twist the robot clockwise, the output is also twisted clockwise with the same velocity. However, when I stop twisting the robot, the output keeps twisting forever with the same velocity. The same happens with possition: if I move the robot forward, the output continues moving forever with the same velocity.
Can you help me with this?
I am new in ROS, so maybe I didn't understand some basic concepts.
You will find the launch file and the YAML file below, as well as some examples of the topics published. As I said, I am new in ROS, so I can't upload files yet. I'll copy-paste them. I can't upload an image of the output of the 'rosrun rqt_tf_tree rqt_tf_tree' command, but I can tell you that odom is linked to base_link, and the children of base_link are odometry and pozyx_frame.
This is the YAML file:
frequency: 30
sensor_timeout: 0.1
two_d_mode: true
transform_time_offset: 0.0
transform_timeout: 0.0
print_diagnostics: true
debug: true
debug_out_file: /path/to/debug/file.txt
publish_tf: true
publish_acceleration: false
map_frame: map # Defaults to "map" if unspecified
odom_frame: odom # Defaults to "odom" if unspecified
base_link_frame: base_link # Defaults to "base_link" if unspecified
world_frame: odom # Defaults to the value of odom_frame if unspecified
odom0: example/odom
odom0_config: [true, true, false,
false, false, false,
true, true, false,
false, false, true,
true, true, false]
odom0_queue_size: 2
odom0_nodelay: false
odom0_differential: false
odom0_pose_rejection_threshold: 5
odom0_twist_rejection_threshold: 1
pose0: /pozyx_pose
pose0_config: [true, true, false,
false, false, true,
false, false, false,
false, false, false,
false, false, false]
pose0_differential: false
pose0_relative: true
pose0_queue_size: 5
pose0_nodelay: false
use_control: false
stamped_control: false
control_timeout: 0.2
control_config: [false, false, false, false, false, false]
acceleration_limits: [1.3, 0.0, 0.0, 0.0, 0.0, 3.4]
deceleration_limits: [1.3, 0.0, 0.0, 0.0, 0.0, 4.5]
acceleration_gains: [0.8, 0.0, 0.0, 0.0, 0.0, 0.9]
deceleration_gains: [1.0, 0.0, 0.0, 0.0, 0.0, 1.0]
process_noise_covariance: [0.5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0.5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0.06, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0.03, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0.03, 0, 0, 0, 0, 0 ...