Robotics StackExchange | Archived questions

Change heartbeat_timeout or heartbeat_period in a nodelet?

I don't want to disable the heartbeat entirely with /bond_disable_heartbeat_timeout, only increase heartbeattimeout and/or heartbeatperiod- ideally via a ros param, but it is looking like they aren't exposed.

https://answers.ros.org/question/9700/nodelets-and-bond-timeouts/ refers to changing the timeout but isn't clear about how they did it- hopefully not by recompiling bond_core?

I see the timeout setting in the following but no other calls to the same method:

https://github.com/ros/bond_core/blob/kinetic-devel/bondcpp/src/bond.cpp#L88

setHeartbeatTimeout(bond::Constants::DEFAULT_HEARTBEAT_TIMEOUT);

Can I get at the bond::Bond within my onInit or elsewhere within my nodelet? I see a bond created in https://github.com/ros/nodelet_core/blob/indigo-devel/nodelet/src/nodelet.cpp#L338 - but it looks like it only lives within that while loop.

Asked by lucasw on 2019-10-16 11:30:28 UTC

Comments

Answers