cannot open audio device plughw:0,0 (Device or resource busy)
Linux - KernelThis forum is for all discussion relating to the Linux kernel.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
My goal:
I want ALSA to stably capture audio to a file and, at the same time, to stream audio on demand.
Note:
- If the ALSA is not kept busy by the audio capture to a file the rtp audio stream works flawlessly.
- The error "resource busy" is clear to me and I understand that.
My question:
Is there a solution to address my goal? In that case how to?
Thank you a lot for the help!
Last edited by sergiomarina; 01-18-2019 at 10:27 PM.
Reason: make clearer my question
thank you.
So you mirrored the MIC into LINE OUT in order to make it seem LINE IN is an new source and stream it separately.
Am I correctly understanding??
Question (which is barely related, but I want to take the chance of your experience):
my ALSA produces some loud noises periodically. Let's say every minute and for about a second.
I hear those noises connecting a loudspeaker to LINE OUT, even if the system is idle and not performing any user related task.
I hear those noises even in the recorded files.
Did you experience a similar issue? In that case, how did you manage it? (I have tested different power supplies with no effects)
PS: based on my previous test on same system (orange pi zero), where I have installed pulseaudio, I prefer to use just ALSA. Am I just a newbie or pulseaudio could really limit the system stability? If so I think I'll solve with a quick and dirty workaround: two separate orange pi (or similar SBC) systems. BTW my d-link camera performs simultaneous recording and streaming on demand.
Last edited by sergiomarina; 01-18-2019 at 10:25 PM.
my ALSA produces some loud noises periodically. Let's say every minute and for about a second.
I hear those noises connecting a loudspeaker to LINE OUT, even if the system is idle and not performing any user related task.
I hear those noises even in the recorded files.
Did you experience a similar issue?
never.
sounds like a serious problem.
I wouldn't even know how to troubleshoot that - maybe have a look at these results.
could it be orangepi specific?
Quote:
based on my previous test on same system (orange pi zero), where I have installed pulseaudio, I prefer to use just ALSA. Am I just a newbie or pulseaudio could really limit the system stability?
i think you're really just a newbie.
pulseaudio is generally stable, and shouldn't take too many resources either (i don't know how powerful orangepi is).
In the attached screen shot the noise waveform as shown by the audio editor.
I think the orange pi produces that noise since:
1) I can hear the noise even if alsa line out is muted
2) no noise if the loudspeaker jack is unplugged
Unfortunately *.wav file can't be attached. You can image the noise as a metallic item (like a screwdriver or a fork) scraping a rough concrete surface.
It must be a HW problem. Therefore could be either orange pi specific or just a defective sample.
As I said I have already tested two different power supplies w/o changes.
To perform audio streaming, have you tested clvc instead of ffmpeg? I do not think it'll solve the "Device or resource busy" issue, but it could be worth a try.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.