Ask Your Question

Include marker position update into robot localization

asked 2021-03-25 08:11:46 -0500

Sidet gravatar image


I'm currently working on a small remote controlled car thats supposed to follow an arbitrary path. The car is eqipped with an optical flow sensor as well as an IMU.

To get the current pose of the car I'm using the robot_localization package.

I managed to fuse odom data from the optical flow sensor with the IMU data using.

Now, in addition, i mounted an aruco marker on the car as well as one on the ground as the corresponding coordinate origin. A usb_cam i detecting the markers and calculating the cars pose in relation to the marker on the ground. The output is A PoseWithCovarianceStamped msg.

My goal is to use the position measurements as a way to set the coordinate origin as well as correct drift by the odom updates.

To fuse odom and Imu data, in the yaml file used to launch the node I used:

odom_frame: odom
base_link_frame: base_link
world_frame: odom
odom0: motion/odom
imu0: imu/data

Now I dont know how to get the ekf to use the position measurements. I tried directly implementing the pose update into the existing yaml file with:

pose0: markerDetection/pose
pose0_config: [true, true, false...

That didn't seem to work. The documentation says to set the world frame to the map frame, however that also didn't do the trick.

I also tried launching two ekf_localization nodes, where one is supposed to fuse odom and imu data and the second one to fuse the position data.

I'm pretty sure the solution is very simple, however I can't seem to understand how to accomplish what I'm trying to do.

Help would be greatly appreciated!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2021-03-29 06:27:32 -0500

Sidet gravatar image

updated 2021-03-29 06:28:03 -0500

Alright I figured it out.

Adding pose0: markerDetection/pose pose0_config: [true, true, false... was the right approach, the problem was, that the machine running the camera marker detection had a wrong system time and date. This caused the Ekf to reject the measurements. By time-syncing the two machines I got it working.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2021-03-25 08:11:46 -0500

Seen: 73 times

Last updated: Mar 29