ROS related notes

mistake one

When RVIZ is used, if the fixed frame option is not set correctly, then the corresponding data information will not be displayed, and an error will be prompted: "For frame [XX]: Fixed Frame [map] does not exist"

There are two ways to report errors such as frame and transform in the topic.
1. Set the global fixed frame to the coordinate system where the topic itself is located. According to the above figure, it should be changed to tramcar;
2. Use the tf package tool to publish global fixed The tf relationship between frame and topic's coordinate system, for example:

 rosrun tf static_transform_publisher 0.0 0.0 0.0 0.0 0.0 0.0 map xxx 100 ;//将xxx映射为map

Then there is another question: where is the name of the coordinate system where the topic itself is located (tramcar in the above picture)?
We know that the topic item (that is, the name of the topic, which corresponds to /cloud in the above figure) is specified in the program. Similarly, the reference coordinate system information of the message is recorded in the frame_id of the message, and this value can be directly in the program. It can also be specified in advance in the .cfg configuration file by assigning a value to the frame_id field of the message header. View the fix frame of a message:

   rostopic echo /cloud | grep frame_id

Guess you like

Origin blog.csdn.net/qq_43200940/article/details/130371590