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

Revision history [back]

When use_sim_time rosparam is true, it uses the clock being published by the simulator. Hence it will return 0 till it receives any clock data from the simulator. Make sure that your Gazebo simulation is running i.e. not in paused state, in order to keep publishing time on /clock topic. For the while loop, you can try using the clock data being published by the simulator on the /clock topic.