Continuous speech recognition in android app without google popup
I am working on a project on "Home Automation" system with Android app and Microcontroller , connecting them through Bluetooth module. I have incorporated "speech to text" for voice commands. Although , it works well with the built-in google speech recognition api. All I need is a continuous speech recognition and without the google voice pop-up. I have seen a similar app on playstore "speechnotes" that works exactly i wish to develop. And it works totally offline.
You should try Droid Speech it supports continuous voice recognition and also will work offline if the speech package for the required language is installed in the device.
Setting the library in your project is very simple and with a few lines of code you can easily start using speech recognition.
An example,
Add the below in your Gradle file,
compile 'com.github.vikramezhil:DroidSpeech:v2.0.3’
In your Activity,
DroidSpeech droidSpeech = new DroidSpeech(this, null);
droidSpeech.setOnDroidSpeechListener(this);
To start droid speech to listen to user voice call the method,
droidSpeech.startDroidSpeechRecognition();
The speech result will be triggered at,
@Override
public void onDroidSpeechFinalResult(String finalSpeechResult)
{
// Do whatever you want with the speech result
}
链接地址: http://www.djcxy.com/p/34390.html
上一篇: iOS是语音识别权限强制性的吗?