New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failed to initialize recorder. Microphone might be already in use... #6
Comments
Sounds about right. Implementation of pocket sphinx on my application requires sole access to the microphone. Unfortunate but workable |
I have killed all other apps and am also having this issue. What do I need to change change to get the demo to work? |
It might be Google Now who acquired the mic.
|
How do i find out? I currently have no apps running in the foreground or background. Is there a way to give pocket sphinx priority? |
Turn off google now functions in settings and try again. Recording should work, you can try with any recording application if it can record or not. If recording work but pocketsphinx does not, this is an issue to investigate, otherwise you need to find the service that blocks your microphone. |
I was receiving the exception and found I had to go into the application manager and turn on the "Microphone" permission manually. This corrected the problem. This probably has to do with the change to permission handling in Android 6 (API 23). Before initializing PocketSphinx you should verify the app has the permission turned on. If not, don't start. |
The demo has the code to request permissions if they are missing, you might just try the recent version. |
I downloaded the demo, opened it with Android Studuo but when I tried to run it, I got the following error:
Error creating AudioRecord instance: initialization check failed.
Error code -20 when initializing native AudioRecord object.
and the phone says:
Failed to init recognizer java.io.IOException: Failed to initialize recorder. Microphone might be already in use.
On a hTC One S( Android 4.1.1 )
The text was updated successfully, but these errors were encountered: