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

This has been asked before. See #q203760.

This has been asked before. See #q203760.

And we could also look at the source: ros::Duration::sleep() eventually calls ros_wallsleep(..), which basically does:

timespec req = { sec, nsec };
timespec rem = {0, 0};
while (nanosleep(&req, &rem) && !g_stopped)
{
  req = rem;
}

and nothing more.