How to change publishing rate of a node to a topic? [closed]
hello,here are the publishing rate on the following topics:--
/odom--->Caverage rate: 5.002 min: 0.193s max: 0.210s std dev: 0.00788s window: 39
/scan--->Caverage rate: 4.997 min: 0.193s max: 0.210s std dev: 0.00782s window: 39
/tf----->Caverage rate: 40.086 min: 0.000s max: 0.112s std dev: 0.04128s window: 250
How can i increase the publishing rate on /odom and /scan topics?
I have a P3AT robot in spawned in the simulated environment (USARSim).
////////////////////////////////////////////////Question Update 1///////////////////////////////////////
hi @gvdhoorn, i have an amcl node which subscribingis to /tf
from rossim at a higher rate and also publishing the /tf
, to others node, i am in a problem because both nodes rossim and amcl are doing both things publishing and subscribing together, now my concern is that i suppose i remapped it like <remap from="tf" to="tf_throttle"/>
then it could also change publishing topic along with its subscribing topic, please take a look on this rqt_graph which is creating problem and confusion.
My rossim Node is publishing to /tf
at the rate of 40hz, i want to rossim to publish at the rate of 5hz, i used throttle
but it publishing at another topic /tf_throttle
at the reduced rate, now if i remap the amcl to subscribe to /tf_throttle
and because publishing to the /tf
also then it might also change it publishing topic and other node like rviz and move_base won't be able to get /tf
data from amcl. please take a look at my rqt_graph
Thanks a lot
////////////////////////////////////////////////Question Update 2///////////////////////////////////////
hi @gvdhoorn,
Here is the scenario, suppose i have a node
n
and two topicst1 and t2
, n is a default publisher oft1
and also subscribes to this topic 't1'.Now i want that node
n
should subscribe to the topict2
instead of topict1
, but at the same time i also don't wantn
to change its publishing topic and it should retain its default publishing topic.
How can i do it because i suspect that remapping can change both topics (publishing and subscribing) for the node n
?? please suggest.
Whatever sends this topics (probably some usarsim driver node) must adjust that.