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

answered 2012-01-11 02:50:03 -0500

joq gravatar image

If you run "rosbag play --clock ..." before your other nodes, it will set use_sim_time for you. If you prefer to launch the other nodes first, be sure to set it yourself, as @michikarg recommends.

In addition, the --clock option causes rosbag play to publish simulated time synchronized to the messages in the bag file to the /clock topic. That way, your other nodes run as if they were executing when those messages were originally published.

If you run "rosbag play --clock ..." before your other nodes, it will set use_sim_time for you. If you prefer to launch the other nodes first, be sure to set it yourself, as @michikarg recommends.

In addition, the --clock option causes rosbag play to publish simulated time synchronized to the messages in the bag file to the /clock topic. That way, your other nodes run as if they were executing when those messages were originally published.

CORRECTION: My mistake, rosbag play does not set use_sim_time for you. Setting it yourself is a good idea. That typically needs to be done before the other nodes start up.

If you run "rosbag play --clock ..." before your other nodes, it will set use_sim_time for you. If you prefer to launch the other nodes first, be sure to set it yourself, as @michikarg recommends.

In addition, the --clock option causes rosbag play to publish simulated time synchronized to the messages in the bag file to the /clock topic. That way, your other nodes run as if they were executing when those messages were originally published.

CORRECTION: CORRECTION: My mistake, rosbag play does not set use_sim_time for you. Setting it yourself is a good idea. That typically needs to be done before the other nodes start up.