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

Revision history [back]

click to hide/show revision 1
initial version

If you're bound to Melodic, I would just write the two workers as separate nodes and then run them together and then they will be in their own processes. Are you trying to use some sort of IPC built into multiprocessing that is not shown here? Otherwise I don't see what your objective is in making them two process written in one node.

If you're not bound by Melodic and can use ROS2, you're looking for Executors which will allow you to write a custom way of work events being picked up.