Robotics StackExchange | Archived questions

How to run multiple nodes in sequence?

Hi all, I have one CPP node and one python node, so I want to run cpp one first and the python one the next. How to combine together? I want to run the first node and run the next node after the first one is done.

Asked by JasonJo on 2022-08-16 16:50:51 UTC

Comments

Answers

Overall, roslaunch won't provide it to you:

roslaunch does not provide any guarantees about what order nodes start in. This is intentional: there is no way to externally know when a node is fully initialized, so all code that is launched must be robust to launching in any order.

It highlights the correct approach to the implementation of robust code, that is easy to reuse later.

There are still some workarounds to it, mentioned in these questions:

Asked by ljaniec on 2022-08-16 17:28:52 UTC

Comments