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

Revision history [back]

Hello!

I don't believe there is a way to get the time without a ROS master since the master is what actually manages the clock (since this can be changed to use simulation time, etc.). Someone might correct me on that.

However, the underlying implementation of the ROS timer is Boost's ptime library from the header boost/date_time/posix_time/ptime.hpp (documentation here), so you could just use that instead. Personally I'd say it would be better to use the Boost clock than have ROS as a dependency for some entirely unrelated project.

-Tim