0
$\begingroup$

Rosanswers logo

Hi there!

I'm running the examples found here: http://wiki.ros.org/rtabmap_ros/Tutorials/MappingAndNavigationOnTurtlebot

Now, I don't have a turtlebot, so my kinect is placed a lot higher up. This makes the map visualize pretty weird in rviz (it's floating in mid air).

How do I offset it to say 1m below it's current position on the z-axis?

Do I make a new frame with /base_link or similar as parent and edit a few launch files, if yes, what launch files? If no, how to move the map?

(Map position is uneditable in rviz)

Let me know if anything was unclear, thank you!


Originally posted by TRyKKs on ROS Answers with karma: 1 on 2016-05-04

Post score: 0


Original comments

Comment by Dox on 2018-07-20:
Hi! I have the same issue. Have you managed to solve it? I only have one static transform between base_link and camera_link. When I add another between base_link and ground I get and error that my tree is not connected.

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Without modifying the robot state published by turtlebot launch file, you could add a static transform between the ground and base_footprint:

<node pkg="tf" type="static_transform_publisher" name="gound_to_base_tf" 
    args="0.0 0.0 1.0 0.0 0.0 0.0 /ground /base_footprint 100" />

You add this to demo_turtlebot_mapping.launch and change base_footprint by ground for rtabmap, rgbd_odometry and rtabmapviz nodes in the same launch file.

This way, the robot would be 1 meter over the ground, so lowering the map from 1 meter.

cheers


Originally posted by matlabbe with karma: 6409 on 2016-05-04

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by Dox on 2018-07-20:
I tried to follow your suggestion but with no success. This is how my transform tree looks with modifications. BTW, Odom is published by Rosaria and it connects to base_link.

Comment by matlabbe on 2018-07-23:
In your case, you cannot do the hack above on your robot, as odometry is already computed accordingly to base_link. You may try to make rossaria publishing odom to a base_footprint frame that would be on ground under base_link, then use base_footprint for rtabmap node.

Comment by Dox on 2018-07-25:
I did try that afterwards, but it seems like rosaria can only publish to base_link frame. I set base_link_frame parameter as base_footprint but I still get the same warning of two unconnected trees. There is no connection between odom --> base_footprint.

Comment by matlabbe on 2018-07-25:
well, in your tf tree, rossaria doesn't seem to publish any odometry

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.