Stivmab
Stivmab

Reputation: 1

How to set the real time factor on gazebo to 1?

I got a question regarding the timing in Gazebo and ROS.

I have a car robot (with velodyne vlp16 LiDAR) which uses Gazebo plugins and some ROS packages. I'm aiming to detect the position of obstacle by moving the car and i would like to synchronize ros and Gazebo namely simulation time and real time on Gazebo. I have read ros time is the same as simulation time when the use_sim_time parameter is enabled. Unfortunately it doesn't work. I also try to set it directly using the parameter <real_time_factor>1</real_time_factor> on my sdf.file but it doesn't work. By running Gazebo and ros i always have in Gazebo real time factor equal to 0,71. I guess it muss be normally equal to 1.

Any idee how to solve this Problem please?

Upvotes: 0

Views: 2583

Answers (1)

BTables
BTables

Reputation: 4843

The gazebo real time factor isn’t just a property you can set and have it work. It’s purpose it to tell you how fast the sim time is running relative to real time. The reason it doesn’t get above .71 is because it can’t keep up computationally. A known problem, especially with older versions of gazebo, is that it isn’t super efficient.

Upvotes: 1

Related Questions