-
Notifications
You must be signed in to change notification settings - Fork 965
Open
Description
The following piece of code (introduced in #753), causes my odometry state to drift due to a nonzero resulting acceleration vector after removing the gravitational acceleration.
robot_localization/src/ros_filter.cpp
Lines 2730 to 2738 in 804729e
| if (!relative) { | |
| // curAttitude is the true world-frame attitude of the sensor | |
| rotNorm = trans.getBasis().inverse() * normAcc; | |
| } else { | |
| // curAttitude is relative to the initial pose of the sensor. | |
| // Assumption: IMU sensor is rigidly attached to the base_link | |
| // (but a static rotation is possible). | |
| rotNorm = target_frame_trans.getBasis().inverse() * trans.getBasis().inverse() * normAcc; | |
| } |
My r_l configuration is as follows
frequency: 10.0
print_diagnostics: true
base_link_frame: "base_link"
world_frame: "odom"
transform_time_offset: 0
two_d_mode: false
publish_tf: true
smooth_lagged_data: true
history_length: 5
odom0: encoder_odom
odom0_nodelay: true
odom0_config: [false, false, false, # X,Y,Z,
false, false, false, # roll,pitch,yaw,
true, true, true, # X`,Y`,Z`
false, false, false, # roll`,pitch`,yaw`,
false, false, false] # X``,Y``,Z``
imu0: imu/data
imu0_queue_size: 20
imu0_remove_gravitational_acceleration: true
imu0_nodelay: true
imu0_relative: true
imu0_config: [false, false, false, # X,Y,Z,
true, true, true, # roll,pitch,yaw,
false, false, false, # X`,Y`,Z`,
true, true, true, # roll`,pitch`,yaw`,
true, true, false] # X``,Y``,Z``I'm aware that no position data is being fused here, so odom might drift with a random walk, but I'm seeing a significant deterioration (and nonzero mean drift, so not purely random) caused by the referenced code. I'm not sure what the theory behind this piece of code is. Could someone please elaborate? @HaoguangYang maybe?
Metadata
Metadata
Assignees
Labels
No labels