Ask Your Question
0

Display topic as mark on rviz and mobile robot model too

asked 2019-10-07 21:26:49 -0500

kane_choigo gravatar image

Hello, I'm working on ROS kinetic on ubuntu 16.04.

I currently have a topic made of geometry_msgs/PoseWithCovariance and geometry_msgs/TwistWithCovariance and so on. And I want to display this topic on rviz.

So, is it necessary to set its own tf setting newly for display? I don't need any process wrt the topic but just to subscribe and display (as a point mark, eg).

And also I have to display my mobile robot simultaneously. When I launch turtlebot's minimal.launch a rviz showed mobile robot topic. So I investigated minimal.launch files, but I couldn't find the codes wrt the robot model topic. I know I also can resolve this issue by simply launching amcl_demo.launch. But if I can, I'd like to display it on my customized rviz field, not on the amcl's field

Thanks in advance :)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2019-10-08 01:55:29 -0500

Delb gravatar image

About the covariance topics there are already some discussions about it, see #q9295, this rviz issue on github and this blog. There seems to be a rviz_plugin_covariance developped for Fuerte but it's not available for kinetic, so you would have to build from source (if possible).

And also I have to display my mobile robot simultaneously. When I launch turtlebot's minimal.launch a rviz showed mobile robot topic

That's not exactly a topic, the robot model is defined by setting the parameter robot_description, in rviz the field Robot Model will simply read this parameter. You can find it when going further in the minimal.launch that there is the call to robot.launch.xml that will also call the launch file description.launch.xml. In this last file there are those two lines responsible for the definition of the robot model :

  <arg name="urdf_file" default="$(find xacro)/xacro.py '$(find turtlebot_description)/robots/$(arg base)_$(arg stacks)_$(arg 3d_sensor).urdf.xacro'" />
  <param name="robot_description" command="$(arg urdf_file)" />

Just as a note : You also need to use the nodes robot_state_publisher and joint_state_publisher if you want to use TF. They both read the parameter robot_description to generate the TF.

I'd like to display it on my customized rviz field, not on the amcl's field

Can you clarify what is rviz field and amcl field ? Are you talking about the launch files ?

edit flag offensive delete link more

Comments

Thank you for your quick response. The rviz 'filed' is, I meant just the rviz window. I considered which word to use among [field, window, canvas,..] and I chose [field]. In short, the rviz field is a window when the user runs the rviz with [$ rviz] command. Sorry about the confusion...

kane_choigo gravatar imagekane_choigo ( 2019-10-08 02:50:35 -0500 )edit

Don't be sorry I just wanted to fully understand your issue. Rviz is a visualization tool so you can directly say "in rviz" and ros users would understand.

Delb gravatar imageDelb ( 2019-10-08 03:14:28 -0500 )edit

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

Stats

Asked: 2019-10-07 21:26:49 -0500

Seen: 30 times

Last updated: Oct 08