Search code examples
google-glassgoogle-gdk

Google Glass: playSoundEffect doesn't work


I'm trying to add some sound effects to my Glass app to give the user the same sound feedback as in the normal Glass menus. The Glass Developer Guide recommends the following code (https://developers.google.com/glass/develop/gdk/reference/com/google/android/glass/media/Sounds):

AudioManager audio = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
audio.playSoundEffect(Sounds.TAP);

I tried this code in different click handlers and functions but it seems like this example is not working. My Glass plays the sound effects in menus as usual, but playSoundEffect() doesn't produce any sound at all.

Thanks for your help!


Solution

  • I was able to resolve this problem by doing a factory reset.