ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
![]() | 1 | initial version |
My assumption about tf was wrong, the solution was indeed related to laser_geometry. As described here, the Projector uses start and end time of the scan and therefore asks for a timestamp in the future.
So to wait long enough, the call to waitForTransform should be:
if(!gTfListener->waitForTransform(
scan->header.frame_id,
"camera",
scan->header.stamp + ros::Duration().fromSec(scan->ranges.size()*scan->time_increment),
ros::Duration(2.0),
ros::Duration(0.01),
&error_msg))
![]() | 2 | No.2 Revision |
My assumption about tf was wrong, the solution was indeed related to laser_geometry. As described here, the Projector uses start and end time of the scan and therefore asks for a timestamp in the future.
So to wait long enough, the call to waitForTransform should be:
if(!gTfListener->waitForTransform(
scan->header.frame_id,
"camera",
scan->header.stamp + ros::Duration().fromSec(scan->ranges.size()*scan->time_increment),
ros::Duration(2.0),
ros::Duration(0.01),
&error_msg))
![]() | 3 | No.3 Revision |
My assumption about tf was wrong, the solution was indeed related to laser_geometry. As described here, the Projector uses start and end time of the scan and therefore asks for a timestamp in the future.
So to wait long enough, the call to waitForTransform should be:
if(!gTfListener->waitForTransform(
scan->header.frame_id,
"camera",
scan->header.stamp + ros::Duration().fromSec(scan->ranges.size()*scan->time_increment),
ros::Duration(2.0),
ros::Duration(0.01),
&error_msg))