ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I was facing the same problem , the solution was I removed ros::spin(); from the function that O am subscribing to and just left the (ros::spin()) in my main . What makes me think of this solution is that ros::spin() makes the loop repeats more frequently and since hector was flying , the data have not its enough time to be processed so to make the data takes its time to grasp the change I have removed ros::spin()

I was facing the same problem , the solution was I removed ros::spin(); from the function that O I am subscribing to and just left the (ros::spin()) in my main . function. What makes me think of this solution is that ros::spin() makes the loop repeats more frequently and since hector was flying , the data have not its enough time to be processed so to make the data takes its time to grasp the change I have removed ros::spin()ros::spin().