Moved the logic for talking to the system service into a service in the
app - this now lets you close the activity and still be able to receive
events. Additionally, we get CLI support using commands with the intent
com.android.intent.action.MANAGE_SOUND_TRIGGER.
Bug: 29073629
Change-Id: Ie904b73b4414f2c9fded013aeb5e6c6c3a67f5d3
Now supports loading model information from .properties files inside the
app's data directory. This lets you prepare models for your actual
device, rather than just fake data. If no .properties files are present,
falls back to the default fake three models.
Also adds support for playing some trigger audio, so you can use the
same device to (hopefully) have a trigger be detected.
Change-Id: I003849eb11d4995534d4c070838810d4519991f8
Parcelables don't work well with inheritance. So changed the
IRecognitionStatusCallback to have onKeyphraseDetected() and
onGenericSoundTriggerDetected() for those respective events.
Made corresponding changes to AlwaysOnHotwordDetector and SoundTriggerDetector.
Bug: 27250528
Change-Id: Ic08a431e7cc4248c688b05c865348170246de576
When delete is called, now the STH unloads the corresponding models.
Fix bug with keyphrase where a delete call didn't unload (or stop)
the keyphrase model.
Bug: 27279380
Change-Id: Ia34f713d2aecef4102c0f0ccc57b8d2e5febe4bb
- Fix issue when multiple starts cause multiple spurious loads to be sent to
the native layer.
- Fix scrolling issue in the native app.
Bug: 27222043
Change-Id: Iddf36a8b68637f478dc23b001ecbde352db3a5f0
- Refactoring SoundTriggerHelper to handle generic sound models.
- Ability to store multiple models, callback and state information.
- Separate out initialization to be done per voice model, per any model
and per generic model.
- Minor change to the API exposed -- removing the Handler from the
createSoundTriggerDetector call.
- Added callback processing for onRecognitionEvent().
- Added logic for stopAll().
- Changes to the SoundTriggerTestApp to start/stop recognition.
- Multiple models (3).
- Ability to start/stop/load/unload individual models.
Bug: 22860713
Bug: 27222043
Change-Id: Ie5d811babb956bead653fb560a43f1e549ed11bd
This CL implements the SoundTrigger API improvements as given in b/22860713. Only the java-level
parts are implemented in this CL.
Key changes include:
* Addition of a SoundTriggerManager/SoundTriggerDetector system API to manage
the sound-trigger based sound models.
* Addition of a SoundTriggerService service that manages all sound models
including voice (keyphrase) and sound-trigger based models.
* Includes logic to write sound-trigger based models to the database.
* VoiceInteractionManager service now uses SoundTriggerService instead of
SoundTriggerHelper.
Bug: 22860713
Change-Id: I7b5c0ed80702527c4460372efeb5e542d3693a69