[pulseaudio-discuss] PulseAudio project for art installations
brian at bulkowski.org
Tue Sep 24 17:01:52 UTC 2019
Hi, the following open source code is available.
Note that there are four components of note:
SerenityAudio, which drives multiple speakers with raspberry pis and
presents a REST endpoint as well as fetching JSON objects for current
status in case of a restart,
SoundAdmin, which holds state between reboots and give interactive
elements a single server to interface with ( nodejs ),
SoundButtons, which is a short python script to have different buttons
which are Raspberry PI gpio pins, as an example of a simple interaction
and the Admin app, which allows changing the balance of different
"effects", volumes for individual speakers and zones of speakers, and
such. Also written in Node, I think with vue.js. The admin app also
controls fire and leds, because we had all elements in the sculpture.
As noted in my other mails on the project, the three issues with
PulseAudio that slowed me down were:
* My confusion about the "id" system in pulse audio, which has different
IDs for different things and if you're incautious you will present the
wrong ID to the wrong API,
* Running an app like this as a service which needs to auto-restart,
* The proper way to think about the async interface - basically when the
'user' data field of different APIs can be counted on to be accessed for
the last time. Example code is almost exclusively single-file and
terminates with the process, this example of multiple loops and multiple
speakers means you have to do your async "the right way". In this case I
coded to C11's new atomic libraries.
This project did not require tight time synchronization between
speakers, although we may evolve to that in newer sculptures.
Otherwise, PulseAudio performed well, the extraordinarily low CPU use
meant I never worried about that, and by exposing the bus ids of the USB
ports I could accurately control which speaker was which.
It was recommended to me this project would have been better with
Share and enjoy.
On 9/2/2019 12:26 PM, Arun Raghavan wrote:
> On Tue, 3 Sep 2019, at 12:13 AM, Brian Bulkowski wrote:
>> Thanks for the response, if you don't believe this is a good use, I
>> won't bother further. GStreamer, then.
> If you have something working with PulseAudio, it might make sense to keep it and maybe change incrementally rather than going back to the drawing board.
> -- Arun
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the pulseaudio-discuss