LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 05-11-2011, 03:45 PM   #16
malloc
Member
 
Registered: Jul 2010
Posts: 111

Original Poster
Rep: Reputation: 4

I have now attempted to let two instances of mplayer execute and try to use the audio device. The test fails, the second instance is unable to open the device, from the console output I can see it tries both ALSA as well as OSS, to no avail:

Code:
Opening audio decoder: [faad] AAC (MPEG2/4 Advanced Audio Coding)
FAAD: compressed input bitrate missing, assuming 128kbit/s!
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [faad] afm: faad (FAAD AAC (MPEG-2/MPEG-4 Audio))
==========================================================================
[AO OSS] audio_setup: Can't open audio device /dev/dsp: Device or resource busy
[AO_ALSA] alsa-lib: pcm_hw.c:1293:(snd_pcm_hw_open) open '/dev/snd/pcmC0D0p' failed (-16): Device or resource busy
[AO_ALSA] alsa-lib: pcm_dmix.c:1018:(snd_pcm_dmix_open) unable to open slave
[AO_ALSA] Playback open error: Device or resource busy
[AO ESD] esd_open_sound failed: Connection timed out
[AO SDL] Samplerate: 44100Hz Channels: Stereo Format s16le
[AO_ALSA] alsa-lib: pcm_hw.c:1293:(snd_pcm_hw_open) open '/dev/snd/pcmC0D0p' failed (-16): Device or resource busy
[AO_ALSA] alsa-lib: pcm_dmix.c:1018:(snd_pcm_dmix_open) unable to open slave
[AO SDL] Unable to open audio: No available audio device
 
Old 05-11-2011, 08:23 PM   #17
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,264

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Use
Code:
mplayer -ao alsa
I believe mplayer by default tries to use OSS, and alsa-oss will lock the device. You can also set this in mplayer's config file to avoid passing it explicitly.
 
1 members found this post helpful.
Old 05-11-2011, 08:44 PM   #18
malloc
Member
 
Registered: Jul 2010
Posts: 111

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by T3slider View Post
Use
Code:
mplayer -ao alsa
I believe mplayer by default tries to use OSS, and alsa-oss will lock the device. You can also set this in mplayer's config file to avoid passing it explicitly.
Great, thanks, that actually worked -- sorry that I didn't realize that myself, that is actually quite trivial. So in other words software mixing does indeed work with ALSA.

Now I only need to know how to make OSS programs work with software mixing.
 
Old 05-11-2011, 09:22 PM   #19
dimm0k
Member
 
Registered: May 2008
Location: Brooklyn ZOO
Distribution: Slackware64 14.0
Posts: 389

Rep: Reputation: 23
Great to hear you have software mixing working! I suggested running two instances of mplayer to actually test it, as it is the easiest to work and switch to ALSA. That and that's what I used to test when I was trying to figure things out. I hope you realize that xmms can be made to use ALSA as well, so I'm curious as to what programs you use that use OSS specifically?
 
Old 05-11-2011, 09:25 PM   #20
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,264

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Quote:
Originally Posted by malloc View Post
Now I only need to know how to make OSS programs work with software mixing.
It won't unless you run it through a sound server (like phonon or arts or pulse or esd etc.). You should set everything you can to output via ALSA explicitly. If you have an app that will ONLY use OSS then you can start sound from one app that uses ALSA, then start the OSS app and it shouldn't lock the sound device. However, if it is the first app to output sound and it uses OSS then you're out of luck unless it can be routed through a sound server.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Software mixing : Audio chip VT1708S Skcrog86 Linux - Hardware 1 10-20-2010 02:49 AM
amixer / no audio capture from software mixing in Feisty ordealbyfire83 Linux - Software 0 11-28-2007 05:00 PM
Want to develop audio mixing software: Where to start?? tzouse Programming 2 08-04-2006 12:01 AM
audio mixing problem jonhewer Linux - Newbie 6 05-05-2005 11:53 AM


All times are GMT -5. The time now is 04:15 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration