Both are working OK using online and offline downloaded language (Android 4.2.2 and Android 5.0 real devices), but .... only in the debug mode.
Any Release (including non-obfuscated) compilation - stops working speech recognition :-(
Compiled with targetSdkVersion="22", all sub names are with "_", no any system error in the log .....
I can publish the debug and release app APKs to try (it's simple but they are with RU interface).
Erel, it have tried "DisableStrictMode" - no good news.
But why - this SR can work well without Internet at all - it works in debug with offline downloaded language pack.
Hmmmm, as a new project - it's work after Release compilation !!!
UPDATE:
"_onError" sub at my project was "_Error": and i did not get errors, error 5 is here - RESULT_AUDIO_ERROR, mic channel is occupied by other sub listening the silence.
Erel, thanks for idea
Erel, but the question is not answered :-(
I had misprint in event sub name _Error instead of _onError, and this event is not fired. But why in debug mode the app works as needed fully - but when compile as Release - no recognition ?!
If i fix the error in the sub name - i get standard errors from SpeechRecognizer object.
Maybe debug mode uses many DoEvents ?
Debug mode doesn't use DoEvents at all.
On my device it doesn't seem to work in both modes.
I'm sorry but I'm not familiar with this library to further help you.
Hi; i installed your example without the lib; put a startservice in activity create; startserviceat and btn_Start code in Service_Start and it works online with phone asleep in release and debug; where can i get the downloaded language pack to use it offline ? I have no idea what is going on; i like talking to my phone when it is asleep. Thank u
Hi ; here is what I did just added some stuff to your code; it works online; do I need the speech library to use this offline ? I had the language pack already and did not know. Thank u I added example code to suppress some beeps.