fkie / multimaster_fkie

ROS stack with FKIE packages for multi-robot (discovering, synchronizing and management GUI)
BSD 3-Clause "New" or "Revised" License
272 stars 106 forks source link

sync_topics question #97

Closed murikill closed 5 years ago

murikill commented 5 years ago

Hi,

I try to get running multimaster on my two machines. I did tutorials with one machine from there: http://wiki.ros.org/multimaster_fkie/Tutorials/Setup%20a%20ROS%20master%20synchronization, it works perfectly. After that I've tried to use two machines. After exporting my ROS_MASTER_URI I've launched one talker node, master_discovery and master_sync node on the first PC.

On the second PC I've launched master_discovery and master_sync. Then I've typed: rostopic list and I've seen my /chatter topic from another PC.

Next, I wanted to filter the topics, and I've created more chatter nodes on the first PC and modified "sync_topics" in master_sync.launch file, so that only one chatter-topic shall be visible on the second PC. Screenshot 2019-03-13 15:03:27

Different than expected I've seen all chatter topics... Only after copying the master_sync.launch to the second PC I've seen the expected behavior.

My question: do I something wrong or it's has to be like that?

Tank you!

atiderko commented 5 years ago

Hi murikill,

it is expected behavior!

The master_discovery node observes the ROS-Master and offers all the information about ROS-Nodes, Topics and Services. master_sync "only" change the local ROS-Master by registering the remote information. The filter options in master_sync affect the requests from master_sync to remote master_discovery nodes. So if you don't want to see topics on second host you must configure the launch file on second host.

I hope it answers your question. If not, please reopen!