ros-simulation / gazebo_ros_demos

Example robots and code for interfacing Gazebo with ROS
347 stars 225 forks source link

Double Pendulum Reset #29

Open Coder9523 opened 6 years ago

Coder9523 commented 6 years ago

I am facing a problem concerning the synchronization between gazebo clock and tf time stamp once the service "Reset Simulation" is called. So you can reproduce my problem, you have to : 1- launch the simulation by typing in the terminal : roslaunch rrbot_gazebo rrbot_world.launch 2- launch the controllers in another terminal : roslaunch rrbot_control rrbot_control.launch 3- open a third terminal and type : rostopic echo /clock ( you can see the clock has just started counting ) 4- type an another terminal : rostopic echo /tf ( you can see the time stamp is following the clock time ) 5- once you call the rosservice by typing : rosservice call /gazebo/reset_simulation. you can easily notice a desynchronization between the tf topic and the gazebo clock. the clock resetled to zero after the "reset simulation" whereas the tf time stamp remained equal to the last timestep before reset.

Can anyone help me solve this matter ?