Open crabiner opened 2 years ago
I have the same problem. I tried setting use_sim_time
with the command line:
ros2 param set /rviz use_sim_time true
but rviz still does not use the time in the rosbag being played
you're setting the parameter after creating the node, so you'll have to spin a couple of times before the node reads the clock topic properly. Preferably add the parameters to rclcpp::NodeOptions and start the node with those options.
on ros2 galactic I have set "use_sim_time" to true on my custom panel for rviz but the clock is still machine clock and not simulated time I have tried setting the flag on runtime as well, and in callback loop I always see machine clock
see snippet below