Gazebo | Ignition | Community
Ask Your Question
0

Gazebo /clock publish rate

asked 2020-06-09 13:12:37 -0500

fiji3119 gravatar image

Gazebo publishes /clock at 10Hz. Can this be increased and how?

Thank you!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2020-06-09 14:26:33 -0500

nlamprian gravatar image

/clock publishes a message once per every new state, i.e. at 1/max_step_size Hz. You should rather focus on why your simulation runs so slow than the clock publish rate (did you perhaps tweak max_step_size?).

Nonetheless, if you still want to change the frequency, you can do that with the /gazebo/pub_clock_frequency parameter on the parameter server.

edit flag offensive delete link more

Comments

I am using default value i.e max_step_size = 0.001 but when I run ros2 topic hz /clock, I get avg 10Hz. Shouldn't I expect 1000hz?

fiji3119 gravatar imagefiji3119 ( 2020-06-09 18:13:01 -0500 )edit

So, things are different in ROS2. It seems that /clock indeed publishes at 10 Hz. You can find the answer to your question here.

nlamprian gravatar imagenlamprian ( 2020-06-09 19:00:46 -0500 )edit

Exactly what I was looking for. Thank you!

fiji3119 gravatar imagefiji3119 ( 2020-06-10 08:55:27 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2020-06-09 13:12:37 -0500

Seen: 87 times

Last updated: Jun 09