ROS Multi-Machine Publishing
I have been playing around with ROS (ros.org) for a while now but I have kept my development on two machines - the master and one slave. Now that I've brought up another machine I'm starting to run into issues with publishing data between the two slaves. Basically, any nodes I bring up on the master can publish data that either of the slaves can receive. Any channels published by nodes on the slaves can only pass data to another node on the same slave, not even a node on the master.
I'm using SVN, the code is the same from machine to machine. Communication between each slave and the master is defin开发者_StackOverflow社区itely there so the environment is configured properly.
I've written the tutorial code from http://www.ros.org/wiki/ROS/Tutorials/WritingPublisherSubscriber(c%2B%2B) into a couple nodes just to make the testing as basic as possible. Communication between those nodes is as described above.
In summary - where A is the master:
- A > B (Works)
- A > C (Works)
- B > A (Fail)
- C > A (Fail)
- B > C (Fail)
- A > A (Works)
- B > B (Works)
- C > C (Works)
The hostnames for my slaves weren't resolving. Putting entries for each in the hosts files solved the problem.
Your problem is likely your network settings. The ROS/NetworkSetup page talks about how to correctly configure your network.
The usual issue is that ROS nodes use your computers reported hostname to advertise itself to other nodes. However if computers are not configured with fully qualified domains this can lead to partially connected systems.
精彩评论