0
$\begingroup$

Rosanswers logo

I have another problem that need your help,

I built a data.bag using rosbag as tutorial with transform

Heading

#include <ros/ros.h> #include <tf/transform_broadcaster.h>

int main(int argc, char** argv){ ros::init(argc, argv, "urca_hokuyo_tf"); ros::NodeHandle n;

ros::Rate r(100);

tf::TransformBroadcaster broadcaster;

while(n.ok()){ broadcaster.sendTransform( tf::StampedTransform( tf::Transform(tf::Quaternion(0, 0, 0, 1), tf::Vector3(0.1, 0.0, 0.2)), ros::Time::now(),"base_link", "hokuyo_scan")); r.sleep(); } }

, but when i use rosrun gmapping slam.. and rosbag play and rosrun map_sever map_saver. I do not create a map.

Please, show me how can i fix it


Originally posted by ThiemPHAM on ROS Answers with karma: 46 on 2016-12-07

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

First, make sure whether the bag file you have recorded has data or it is empty. This can be done by

rosbag play --clock data.bag

Then echo the topic to check whether the bag file is publishing data.


Originally posted by Gokul with karma: 243 on 2016-12-07

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

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