Does anyone know how to synchronize the 2 clocks of Webots? the one of the console and the environment clock? because I am trying to use the internal python clock to define rotational movements and I cannot rotate at the desired angles because of the asynchronous clocks
Asked
Active
Viewed 100 times
1 Answers
1
Webots does not use the environment clock, it computes a "simulated time" based on the simulation events (mainly the physics discrete steps asked by the controller). Therefore, the controller and any library used by a Webots controller should use only the simulated time provided by Webots.
This can be achieved by calling the wb_robot_get_time function which changes at each wb_robot_step calls.

FabienRohrer
- 1,794
- 2
- 15
- 26