What is the best approach if I need a topic to have a subcriber just for the sake of actual communication taking a place?

asked 2019-05-23 07:35:53 -0500

kump gravatar image

I am using the Multimaster FKIE package to connect two ROS masters. The master_sync node whose job is to detect communication on ROS core #1 and copy it onto the second ROS node #2, however, would not see messages that are being published to a topic on ROS core #1, unless there would be a node on ROS core #1 that is subscribed to that topic.

I do not need this topic to be read in ROS core #1. I only need to transfer the messages to ROS core #2. So what would be the cleanest approach to this problem? I know I can simply run a node that only subscribes to the topic and let it do nothing. I was thinking about subscribing to the topic inside the node that publishes the topic. I don't know how that would work. Is it possible? Is it ugly solution? Is there any other more suitable mechanism?

edit retag flag offensive close merge delete