aserver + shm plug-in information?

Stuart Longland stuartl at longlandclan.id.au
Sat Aug 22 08:36:26 CEST 2020


[Hi all, I sent this to the alsa-user list about 2 months ago, and
haven't seen any replies.  Hoping someone here might know?  Thanks in
advance.]

Hi all,

I'm looking at ways to try and share a sound card over a network in a
lossless and low-latency manner.

The application here will be to be able to use the sound card on a
Raspberry Pi to interface to an amateur radio transceiver, and use that
interface to send things like slow-scan television from a more powerful
workstation.

For this to work, it is utterly *essential* that no audio compression is
used.  So PulseAudio, JACK, etc… unless I'm very much mistaken, are not
options as they use lossy audio CODECs for compression.  Audio itself
might only be 8kHz at 16-bit linear PCM, mono… so not terribly high
bit-rate, and even latency is negotiable, but lossy compression is
likely to mess things up.

PulseAudio I'd imagine is also asking for trouble where digital modes
are concerned, as it'll be trying to re-sample everything to keep a
consistent sample rate.  I want as little extra DSP on streams as
possible.  I'd prefer to let PulseAudio just handle "audio" only.

I'm considering writing an ALSA PCM plug-in to accomplish this, that
would expose a "virtual" sound card on my workstation, and allow me to
stream it (by custom protocol, RTP, whatever) to another machine.  In
researching this, I've stumbled on the `shm` plug-in.

https://www.alsa-project.org/alsa-doc/alsa-lib/pcm_plugins.html#pcm_plugins_shm

It apparently talks to something called `aserver`.  `man aserver` gives
me nothing.  Google search just takes me to its source code.  There
seems to be scant information about what this does, how to configure it,
etc.

Alternatively, it'd be nice to know how `aserver` and the `shm` plug-in
communicate, maybe I can write my own client daemon that acts like
`aserver` and looks after streaming to the desired end-point.

Alternatively, if people feel I'm barking up the wrong tree, I'm willing
to consider alternatives.

Regards,
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.


More information about the Alsa-devel mailing list