[Twisted-Python] broadcasting in Twisted?

Bob Ippolito bob at redivi.com
Wed Apr 16 08:47:31 MDT 2003


On Wednesday, Apr 16, 2003, at 10:16 America/New_York, Erik Bakker 
wrote:

> First of all I'd like to introduce myself. My name is Erik Bakker and 
> i'm a
> student at the university of Twente in the Netherlands. I'm working on 
> a
> project, in which we would like to use Twisted-python. We are making a
> distributed 3D world using OpenGL in python. And we like to use 
> Twisted for
> the distribution. We don't need to distribute lots of data, in fact we 
> only
> need to distribute the 3D camera position (and only if the 3D camera
> changes on input from the user). We would like to broadcast the camera
> position to all clients but how is the big question. I can't find 
> anything
> in the documentation about broadcasting (except that it is possible:). 
> Now
> was our idea that it should be possible with the module UDP from the
> internet package, but we can't get it to work.
> Now my questions are if it is possible to broadcast using twisted and 
> how.
> I'm a bit a newbie in Twisted (yet;-) anybody got any idea's, examples?

There is fledgling Multicast UDP support in Twisted, but I don't think 
anyone has really tried to use it yet.  Are all clients expected to be 
on the same subnet?  If not, multicast or broadcast is probably not 
going to be appropriate.

As far as implementation goes, take a look at the UDP howto, and 
echoclient_udp.py and echoserv_udp.py in doc/examples.  I haven't used 
UDP since the API for using UDP changed, so I can't really help you any 
more than that.

-bob





More information about the Twisted-Python mailing list