Alexander Khasymski wrote:
Hi,

I was wondering if there is a way to implement simple message passing
between two robots with different brains? I'm doing a project in
language evolution and need a way for robots to pass short strings (5-6
characters) to each other.  The only obvious way I could think of was
implementing a brain that controls both robots, in which case message
passing would boil down to modifying a few global variables, however I
could not find out how to create such a brain part from the fact that it
is possible to do so. Any suggestion, comments, examples of something
similar will be greatly appreciated.

You could have one python program control many brains, but it might just be easier to implement some simple message-passing. Take a look at the other PyRO (Python Remote Objects), for example. Also, it is very easy just to open a socket and send strings, or serialized Python objects. Take a look at the "pickle" module.

Depending on what the speed that you wish to send messages, you could use the simple Instant Messaging protocol that I have written for a new project called Myro. You can find the sources at http://wiki.roboteducation.org/

under Developer. Look at the code in chat.py. It is relatively slow, but allows a human to also send messages, and provides an easy debugger.

The fastest, easiest method, though, is just open direct connections to/from each robot.

-Doug

Thanks,

Aleksandr

_______________________________________________
Pyro-users mailing list
[email protected]
http://emergent.brynmawr.edu/mailman/listinfo/pyro-users



_______________________________________________
Pyro-users mailing list
[email protected]
http://emergent.brynmawr.edu/mailman/listinfo/pyro-users

Reply via email to