Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
paplay+aplay make Device or resource busy[SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
jiaxi
n00b
n00b


Joined: 25 Sep 2012
Posts: 30

PostPosted: Sun Apr 28, 2013 8:56 am    Post subject: paplay+aplay make Device or resource busy[SOLVED] Reply with quote

ALSA and PA are in my system. And it is ok when using aplay or paplay alone.

1) i can hear music using the cmd: paplay 48.wav &.
2) i use aplay 16.wav to play another music.
3) i can get the error log.

/etc/asound.conf:
pcm.!default {
type plug
slave.pcm "dmixer"
}

pcm.dmixer {
type dmix
ipc_key 1026
slave {
pcm "hw:0,0"
rate 48000
period_size 800
buffer_size 3200
}
}



# paplay 48.wav &
# Home directory not accessible: Permission denied

# aplay 16.wav
ALSA lib pcm_dmix.c:1018:(snd_pcm_dmix_open) unable to open slave
aplay: main:696: audio open error: Device or resource busy



I think PA will use hw:0 as sink.So i can get resource busy log when us aplay to play another music using hw:0,0.

And my question can we set PA use "default" as sink?


Last edited by jiaxi on Thu May 02, 2013 2:24 am; edited 1 time in total
Back to top
View user's profile Send private message
salahx
Guru
Guru


Joined: 12 Mar 2005
Posts: 530

PostPosted: Mon Apr 29, 2013 6:44 am    Post subject: Reply with quote

In /etc/pulseuadio/default.pa there is a line (note it is probably commented out):
Code:
load-module module-alsa-sink

One parameter called "device" (the value defaults to "default" if unspecified) if you want to manually specify a device:
Code:
load-module module-alsa-sink device=dmixer

Other paramters are available too: see PulseAudio module documentation.
Back to top
View user's profile Send private message
jiaxi
n00b
n00b


Joined: 25 Sep 2012
Posts: 30

PostPosted: Thu May 02, 2013 2:24 am    Post subject: Reply with quote

salahx wrote:
In /etc/pulseuadio/default.pa there is a line (note it is probably commented out):
Code:
load-module module-alsa-sink

One parameter called "device" (the value defaults to "default" if unspecified) if you want to manually specify a device:
Code:
load-module module-alsa-sink device=dmixer

Other paramters are available too: see PulseAudio module documentation.


Thanks, It is OK using your configuration.

PulseAudio app will also use dmix to mixing with ALSA app.

So it is no advantage of pulseaudio in this case except all application is base on pulseaudio?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum