[Twisted-Python] twisted server for recording streaming audio

exarkun at twistedmatrix.com exarkun at twistedmatrix.com
Fri Nov 6 08:01:33 EST 2009

On 07:28 am, josef.robert.novak at gmail.com wrote:
>  I'm interested  in using twisted to build a server for recording 
>audio.  I've spent some time googling and looking through the archives 
>haven't been able to find much in the way of examples for this sort of
>usage.  To be clear, I'm not trying to stream media from the server to 
>client, but want to stream the audio from (potentially multiple) 
>clients to
>the server, where it will be recorded and possibly later annotated for
>  The closest possible example of this sort of usage scenario that I was
>able to find was shtoom, but I wasn't able to get very far with that, 
>as the
>source does not seem to be available, despite the site still being up
>(perhaps I just couldn't find it ).
>   Does anyone know of any working examples of such usage that might be
>easily adapted.  I'm really only looking for the simplest possible base
>example that would allow me to connect one or more clients over 
>and stream the audio to the server.
>   On the other hand, perhaps it is better to just go with the bundled
>SocketServer module to start with?

"Stream" doesn't mean a whole lot - at least not specifically.  The only 
interesting thing it really implies, I think, is that the data you're 
sending only comes into existence shortly before you send it.

The way to stream audio with Twisted is just like the way you would send 
any other data with Twisted.  Open a connection and start writing to it. 
For documentation about how to do this, see the client and server 


If you run into specific problems or have any more specific questions, 
don't hesitate to ask. :)


More information about the Twisted-Python mailing list