I have an Android app that is used to play audio via the phone's speaker continuously, including when other apps are in the foreground, or the screen is off.
There is however a problem with that app in that the audio it plays can trigger the "OK Google" hotword detection, which leads to a bit of an endless loop, since the app also rewinds a few seconds upon being paused.
Thus there is no choice for the user but to disable the hotword detection entirely and permanently. That is not optimal.
Is there an API call that the app can use to disable the hotword detection temporarily while it is playing audio?
The "Google keeps stopping" error (and others) can be largely attributed to software updates. If the error has just started happening, there is a good chance that a standard system update, an app update, or even a hotfix has caused it.
Turn Off OK Google on an Android PhoneSelect Google > Account Services > Search, Assistant & Voice. Tap Google Assistant. Select the Assistant tab, and then scroll down to the Assistant devices section and tap Phone. Tap on the Google Assistant slider to turn it off.
Accidentally pressing the home button can also trigger the Google Assistant, which can be annoying at times. You can remove Google as your default assistant app, which will stop it from popping up. Open Settings on your phone. Go to Apps and notifications > Default apps.
Hotword detection disabled with accessibly service :
To prevent false positives, hotword detection is disabled when a spoken feedback service is enabled.
You have defined your service as providing all possible types of feedback, which includes spoken.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With