Multimaster is a great tool to use. However it is difficult to use tools like those within running ROS nodes. Also it is impossible to send directed messages between robots. Which makes sense since it is designed for a publish/ subscribe architecture.
A great way to get around this is to use Python-ZeroMQ. You could simply open a socket, send your ros msg object and receive it on the other end as a ros msg object.
The serialization/ deserialization stuff is taken care of internally. One could potentially do serilization/ deserialization manually as well using pickle library in Python. Message me if you need help broadcasting/ unicasting messages between separate ros masters, and I could give you some code.
Originally posted by Ammar with karma: 289 on 2012-10-03
This answer was NOT ACCEPTED on the original site
Post score: 1
Original comments
Comment by hiccup on 2013-04-25:
Hello Ammar, I am trying to communicate between two robot, one on ROS-fuerte and one on ROS-groovy and I think it would be simpler to go directly via the socket than use the multimaster package. Or is multimaster_experimental backward compatible enough to be used? I would appreciate any help!
Comment by pablocesar on 2015-12-24:
Hi, I'm going to do something similar with c++/Python/Cython and zeroMQ, I'll like any help or Githup from you, Thanks ;-)
Comment by ramya on 2016-10-17:
Hello, I am working on something similar which requires me to communicate between multiple robots. I was wondering if you can provide me any help on how to communicate between separate ros masters?