//first, we'll publish the transform over tf geometry_msgs::TransformStamped odom_trans;
odom_trans.header.stamp = current_time;
odom_trans.header.frame_id = "odom";
odom_trans.child_frame_id = "base_link"; odom_trans.transform.translation.x = x;
odom_trans.transform.translation.y = y;
odom_trans.transform.translation.z = 0.0;
odom_trans.transform.rotation = odom_quat;
//send the transform
odom_broadcaster.sendTransform(odom_trans);
//next, we'll publish the odometry message over ROS
nav_msgs::Odometry odom;
odom.header.stamp = current_time; odom.header.frame_id = "odom";
odom.child_frame_id = "base_link";
I could successfully compile it and also ran the teleoperation node I made for the pioneer.
2. During the meeting with Renato we reviewed the process of transformations that should take place when creating the map using the RosAria node and the sicklms node. We agreed that the transform tree should look like this:
3. I then ran the sicklms node and could see its readings in rviz which means that the connection was being made properly. However, when I ran rosrecord I didn't get a bag file that had a correct content. I did several attempts using rosrecord with the odom, base_laser_link and base_scan topics.
4. I saw that the topic published by sicklms node is base_scan. However, it isn't yet clear for me if this node should have a frame that participates in the transform tree. What I saw in the node's code was the following:
ros::NodeHandle nh;
ros::NodeHandle nh_ns("~");
ros::Publisher scan_pub = nh.advertise
nh_ns.param("port", port, string("/dev/ttyUSB1"));
nh_ns.param("baud", baud, 38400);
nh_ns.param("inverted", inverted, false);
nh_ns.param
I wonder if the "laser" frame should be included in the tree or it should be substituted by the base_laser_link frame.
Or perhaps the base_scan topic should be substituted by a topic of the same type.
No hay comentarios:
Publicar un comentario