[ros-users] Message proxy?

Karan, Cem F CIV (US) cem.f.karan.civ at mail.mil
Mon Jul 2 19:20:38 UTC 2012

Hi all, I'm trying to pass data between multiple robots in a manner
similar to what multimaster (http://ros.org/wiki/multimaster) is/was
supposed to do, but after some work, I've realized that what I'm really
trying to do is proxy messages from one robot to another.  I can do this
by grabbing a message and asking it for its serialized representation, and
then rsyncing that across the network, but I realized that that leaves 2
potential problems:

1) I don't know how portable the serialization format really is.  Can I
take a message that was serialized on a little endian 32 bit machine (x86)
and forward it to a big endian 16 bit machine (ARM), and have the data be
correctly serialized/deserialized?  I know I can do this via google
protocol buffers (https://developers.google.com/protocol-buffers/) or
MessagePack (http://msgpack.org/), but I'm not too sure if I can do this
with serialized message format that ROS uses.

2) Is the message type encoded into the serialized data?  It doesn't
appear so, but I just wanted to make sure.  This affects what kind of
proxy I can make; if the message type is encoded in the message, then the
proxy can be oblivious to messages, and will simply forward the data
along.  The receiver can likewise be oblivious, putting the message 'on
the bus' and letting all listeners decode what they want.  Conversely, if
the messages don't encode their own type, then the proxies will need to
know every message type that they encode; otherwise, the receivers won't
be able to put the right message type 'on the bus'.

Any help/pointers would be appreciated.

Cem Karan

More information about the ros-users mailing list