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

simple method to detect node crashes

asked 2015-05-30 06:23:58 -0500

Marcus gravatar image

Hey guys,

I am searching for a simple way to detect a node crash. I saw this already and the answer looks pretty simple to implement. However, the project I am working on has around 15+ nodes running at the same time and it looks like I would have to set a watchdog for each one of them.

Since the master does provide a message in the terminal whenever a node has crashed I was wondering if there is not an even more simple way to achieve my goal. Preferably even something that is only sending me a message when a node has crashed and therefore does not "clog" up the communication. Apparently (have not tested it yet) $rosnode list$ provides a list of all active nodes. I was wondering if I could periodically call this from within my .cpp-file (if I set the sampling rate low enough it should not interfere with other communication). I have seen that it is possible to do so for several other ROS commands that I usually only use in the terminal (find package path etc.).

What do you guys think?

Thanks, Marcus

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2015-05-30 07:02:16 -0500

gvdhoorn gravatar image

I think this is what the bond pkg is for.

edit flag offensive delete link more

Comments

Thank you, I will check that out right away

Marcus gravatar image Marcus  ( 2015-05-30 07:22:26 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2015-05-30 06:23:58 -0500

Seen: 1,792 times

Last updated: May 30 '15