ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

Rviz fixed-frame selections

asked 2012-02-19 17:30:52 -0600

jfetsch gravatar image

When I open rviz after starting gazebo, rviz auto-selects /odom for the fixed-frame. However, in the pull-down menu, /odom does not appear, and the robot is not visible when /odom is selected. Instead, I have to select some other reference frame on the turtlebot, if they are available. Sometimes, even when /odom is selected automatically, nothing appears in the drop-down fixed-frame menu, and I cannot do anything to make the robot appear. Is there any way to change either of these things from happening? There does not seem to be any reason why one happens instead of the other, and sometimes the pull-down menu is populated after quitting rviz when it was not, and sometimes it works the other way around.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
1

answered 2012-02-19 21:03:57 -0600

Kai Bublitz gravatar image

updated 2012-02-19 21:07:00 -0600

I too noticed that rviz sometimes has problems restoring settings and filling the Fixed Frame dropdown properly.

You could try the following steps:

  • While RVIZ is running configure it the way it sould be, if the dropdown is empty just type the name of a valid frame
  • Manually save the rviz config to a vcg file
  • When you start rviz specify the parameter -d and give it the path to your vcg file

In a launch file it could look like this:

<node pkg="rviz" type="rviz" name="rviz" required="true" args="-d $(find your_stack)/test.vcg"/>

I had to repeat this twice, but after that I allways get the correct frame selected on startup

Another option could be using the visualization_experimental stack. This includes a new version of rviz that uses qt. But I have not yet tried this, so I can't tell if rviz_qt handles configurations better.

edit flag offensive delete link more

Comments

That sounds promising, thank you - how do I save the rviz config?

jfetsch gravatar image jfetsch  ( 2012-02-21 16:58:04 -0600 )edit

You can select "save config" fro the rviz file menu or just press ctrl+s

Kai Bublitz gravatar image Kai Bublitz  ( 2012-02-21 22:48:48 -0600 )edit
1

answered 2012-02-19 21:54:44 -0600

dornhege gravatar image

The dropdown menu is automatically populated by tf. So the reason for /odom not being displayed is that probably no odometry is published. That would also explain why you can't see the robot.

When someone publishes odometry tf information you should also have the selection in the dropdown menu.

edit flag offensive delete link more

Comments

I agree on the fact that the robot is not shown properly if odom frame is not published but selected as fixed frame. However it is possible that the robot is displayed correctly but the dropdown is empty.

Kai Bublitz gravatar image Kai Bublitz  ( 2012-02-19 23:02:38 -0600 )edit

In my experience that happens only if there is no tf and I would actually consider it a bug otherwise.

dornhege gravatar image dornhege  ( 2012-02-19 23:23:31 -0600 )edit

Question Tools

Stats

Asked: 2012-02-19 17:30:52 -0600

Seen: 2,730 times

Last updated: Feb 19 '12