Ask Your Question

T265 odometry TF translation node

asked 2020-06-19 13:56:15 -0600

whoobee gravatar image

updated 2020-06-19 16:03:14 -0600

I have this robot where I want to setup the ROS navigation stack on it.

Robot Picture Robot Image

I am using ROS Melodic on an UDOO Bolt (Ununtu machine).

For the odometry I am using an Intel Realsense T265 which is mounted on the robot as shown in the picture above.

The laser is an YDLidar which is mounted underneath the robot.

The current problem which I have (and from a throw google search I am not the only one) is that I cannot correctly connect the T265 odom in my TF.

If I use the T265 odom TF frame and I do a static transform from the T265_pose_frame to my base link, I have the problem that my odom frame is above my laser scan, and the move_base local costmap is not trowing errors that the origin of the sensor is out of map bounds:

[ WARN] The origin for the sensor at (0.35, -0.02, 0.23) is out of map bounds. So, the costmap cannot raytrace for it.

Therefore I decided to not use the TF of the Intel Realsense, but instead to try an create a node in python which is listening on the odometry messages of the T265 and it is generating the TF which directly linked to base_link (see TF view-frames below)

TF Frames TF Frames Image

Currently if I do not modify the data from the T265 at all, and I publish the TF based on the odometry input, I have the following behavior:

Odometry Odometry GIF

because the T265 is connected with an offset of 0.307 on x and 0.21 on z.

I am not that good with the geometry problems :) can you please give me some advice how to correct the translation issue (remove the "hole in the middle")?

I tried the obvious "solution" to subtract from the x and y odometry the (sin(θ) * hole_radius) and (cos(θ) * hole_radius), but ofcourse this does not work, because the T265 odometry always starts from 0, and then the whole TF is translated. Does the ros_tf2 package already provide some kind of API to make this translation programatically?

Or is there maybe a better solution to this problem?

Sorry, I do not have karma points to upload the pictures.. therefore I put some links..

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2020-09-27 07:22:48 -0600

whoobee gravatar image

updated 2020-09-27 07:23:07 -0600

Seems that my problem was very "stupid" and I did not realize that the data from the T265 is in quaternion... Therefore I made a node to make the correct translation of the TF. If someone is interested please have a look at: ROS sensor_odom_manager I am using the T265 in a differential drive robot, therefore this node might not work in other situations.. feel free to modify/fork it...

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

1 follower


Asked: 2020-06-19 13:54:08 -0600

Seen: 760 times

Last updated: Sep 27 '20