sound doesn't work until I login

Karl Auer kauer at biplane.com.au
Fri Sep 9 18:05:35 UTC 2016


On Thu, 2016-09-08 at 17:12 +0300, Thierry Andriamirado wrote:
> > No browsers. No GUI. No screen, no keyboard, no mouse. No users, no
> > logins, no sessions. Just music.
>> So what you needbis just plain ALSA. Without pulseaudio, which you
> have to desactivate.

That's what a couple of people, including Ralf, have suggested.

So I've run up a raspberry pi and modified my script to use ALSA
instead, and it all works beautifully.... with one exception.

To allow my system to play any format of music, the command that
actually delivers sound is this for pulseaudio:

   avconv -i file.ext -f wav - | play -t wav - 

That works very well. aplay looks like it should work too, but it
doesn't. This command:

   avconv -i file.ext -f wav - | aplay -t wav -

...doesn't play anything on the Pi. Nothing at all. Not static,
nothing. And it seems to exit immediately, regardless of how big the
input file is. But it *does* play back on my Ubuntu laptop.

If I convert the file and then play it, it works on both the Pi and my
laptop:

   avconv -i file.ext -f wav x.wav ; aplay -t wav x.wav

Regards, K.

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Karl Auer (kauer at biplane.com.au)
http://www.biplane.com.au/kauer
http://twitter.com/kauer389

GPG fingerprint: E00D 64ED 9C6A 8605 21E0 0ED0 EE64 2BEE CBCB C38B
Old fingerprint: 3C41 82BE A9E7 99A1 B931 5AE7 7638 0147 2C3C 2AC4







More information about the ubuntu-users mailing list