summaryrefslogtreecommitdiff
path: root/services/voiceinteraction/java/com/android/server/soundtrigger/SoundTriggerInternal.java
Commit message (Collapse)AuthorAgeFilesLines
* add API for ST clients run in battery saver modeNicholas Ambur2021-01-221-2/+4
| | | | | | | | | | | | | | | | | | | | | New system API interface for both SoundTriggerManager and AlwaysOnHotwordDetector to indicate if a recognition should run in battery saver mode or not. Clients supply this information through the existing startRecognition calls, and the client must hold a new privledged permission, SOUND_TRIGGER_RUN_IN_BATTERY_SAVER, to indicate this intention. As a prerequisite, the device PowerManagerService must have the SoundTrigger service enabled in the battery saver mode battery policy. If not enabled, recognition will be paused as if the client did not provide the indication to run in battery saver mode. Bug: 172294448 Test: build with Google search apk using this feature and verify recognition keeps running in battery saver mode Change-Id: Ia43be99290e6fd7c50ff8e4908d6c60ea513b19a
* fix SoundTrigger overwriting session identityNicholas Ambur2020-11-161-6/+1
| | | | | | | | | | SoundTrigger tracks client UID for every session. This CL fixes an issue with client UID being saved twice causing the incorrect client UID to be saved. Bug: 171342256 Test: boot and verify hotword is functional Change-Id: I68bba238293ed5a74f5a3677f21e5122cc444f82
* Clean up on client death in SoundTriggerServiceYtai Ben-Tsvi2020-11-111-2/+5
| | | | | | | | | This change adds tracking of SoundTriggerService client death and frees up resources whenever that happens. Test: Kill Now Playing process and observer recovery. Bug: 171026874 Change-Id: Ie31d0a3ed392b1513b4e81ec3c344f4e79adcf52
* Sessionize the SoundTriggerService layer.Ytai Ben-Tsvi2020-09-101-80/+99
| | | | | | | | This changes associates identity information with every SoundTrigerService session. Change-Id: I30c9177f21203c8f3d03d4ff31523137497e760b Bug: 163865561
* add parameter control to AlwaysOnHotwordDetectorNicholas Ambur2020-01-091-5/+57
| | | | | | | | | | Per-model control to AlwaysOnHotwordDetector interface. Models are selected by keyphrase and locale associated with the AlwaysOnHotwordDetector instance. Bug: 141929369 Test: tested manually with test app Change-Id: Iffeb0954059fa030d8a4fefb934a3e665323be37
* VIMS should only stop the keyphrases it started.Chris Thornton2016-05-021-5/+3
| | | | | | | | | | | When the VIMS changes the implementation or has its implementation force stopped, it used to stop all the recognitions that were in the SoundTriggerService (without letting those clients know that they've been stopped). Instead, the VIMS should just unload the keyphrases that it loaded, so the other clients are not perturbed. Bug:28518547 Change-Id: Ia70e8576f43cb8a8521c947ff7fc56f63cfbad54
* Unload logic for generic and keyphrase sound models.Arunesh Mishra2016-02-221-0/+2
| | | | | | | | | | 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 moduleProperties in SoundTriggerInternal.Arunesh Mishra2016-02-011-6/+1
| | | | Change-Id: Ie7ea74ca39894f78875768dbc3e504b32f262fe6
* SoundTrigger API improvements.Arunesh Mishra2016-01-271-0/+84
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