ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

How do I know the maximum rate my publisher can publish?

asked 2015-05-04 09:14:25 -0600

mmodetb gravatar image

I need to publish the information of 4 sensors as quick as possible, could anybody tell which is that rate?

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2015-05-04 09:21:40 -0600

bvbdort gravatar image

use $ rostopic hz /topic_name to know frequency of publisher.

check rostopic hz

edit flag offensive delete link more


But I know the value of the frecuency, because I have declare it. I just want to make as big as fast as possible. How do I know that?

Thank you,


mmodetb gravatar image mmodetb  ( 2015-05-04 09:44:13 -0600 )edit

it depends on frequency of sensors. how did you declare the publisher frequency ?

bvbdort gravatar image bvbdort  ( 2015-05-04 10:22:14 -0600 )edit

Then sensors are giving information all the time. They are a current and a voltage sensor. I declare the frequency of the publisher by using a while loop: rate = rospy.Rate(100) while not rospy.is_shutdown(): pub.publish(state) rate.sleep() thank you!

mmodetb gravatar image mmodetb  ( 2015-05-04 10:57:37 -0600 )edit

answered 2018-01-28 19:47:24 -0600

I don't see any documentation of a maximum rate. It's probably system-dependent. On my machine which is a Lenovo T430 laptop, the maximum publication rate I have measured using a simple test program is about 30 khz.

edit flag offensive delete link more

Question Tools


Asked: 2015-05-04 09:14:25 -0600

Seen: 2,118 times

Last updated: May 04 '15