CsabaConsulting / InspectorGadgetApp

Open Multi-Modal Personal Assistant
MIT License
3 stars 1 forks source link

TTS initialization error on a FAW (Full Android Watch) #14

Closed MrCsabaToth closed 1 month ago

MrCsabaToth commented 1 month ago

The Watch is a LEMFO LEMP Android 9 watch. When the app starts and the various native sections get initialized, the TTS emits an error:

E/AndroidRuntime(14892): FATAL EXCEPTION: main
E/AndroidRuntime(14892): Process: com.google.android.tts, PID: 14892
E/AndroidRuntime(14892): java.lang.RuntimeException: Unable to create service com.google.android.apps.speech.tts.googletts.service.GoogleTtsService: java.io.UncheckedIOException: Error reading bundled metadata. Commonly this is caused by using a wear build on a phone or vice versa.
E/AndroidRuntime(14892):    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3601)
E/AndroidRuntime(14892):    at android.app.ActivityThread.access$1300(ActivityThread.java:204)
E/AndroidRuntime(14892):    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1674)
E/AndroidRuntime(14892):    at android.os.Handler.dispatchMessage(Handler.java:106)
E/AndroidRuntime(14892):    at android.os.Looper.loop(Looper.java:193)
E/AndroidRuntime(14892):    at android.app.ActivityThread.main(ActivityThread.java:6865)
E/AndroidRuntime(14892):    at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(14892):    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:504)
E/AndroidRuntime(14892):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
E/AndroidRuntime(14892): Caused by: java.io.UncheckedIOException: Error reading bundled metadata. Commonly this is caused by using a wear build on a phone or vice versa.
E/AndroidRuntime(14892):    at bpc.f(PG:54)
E/AndroidRuntime(14892):    at bxm.a(PG:9)
E/AndroidRuntime(14892):    at bxl.b(PG:346)
E/AndroidRuntime(14892):    at ila.b(PG:16)
E/AndroidRuntime(14892):    at com.google.android.apps.speech.tts.googletts.service.GoogleTtsService.onCreate(PG:131)
E/AndroidRuntime(14892):    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3589)
E/AndroidRuntime(14892):    ... 8 more
E/AndroidRuntime(14892): Caused by: java.io.FileNotFoundException: voices-list-wear-dsig.pb
E/AndroidRuntime(14892):    at android.content.res.AssetManager.nativeOpenAsset(Native Method)
E/AndroidRuntime(14892):    at android.content.res.AssetManager.open(AssetManager.java:744)
E/AndroidRuntime(14892):    at android.content.res.AssetManager.open(AssetManager.java:721)
E/AndroidRuntime(14892):    at bpc.f(PG:12)
E/AndroidRuntime(14892):    ... 13 more
MrCsabaToth commented 1 month ago

The message is kind of telling "Commonly this is caused by using a wear build on a phone or vice versa.". This is not a Wear OS on a phone, but the question is what is the 'vice versa' case. Because this is a full Android on a Watch and that use-case might fit that.

Another same error:

E/AndroidRuntime(18797): FATAL EXCEPTION: main
E/AndroidRuntime(18797): Process: com.google.android.tts, PID: 18797
E/AndroidRuntime(18797): java.lang.RuntimeException: Unable to create service com.google.android.apps.speech.tts.googletts.service.GoogleTtsService: java.io.UncheckedIOException: Error reading bundled metadata. Commonly this is caused by using a wear build on a phone or vice versa.
E/AndroidRuntime(18797):    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3601)
E/AndroidRuntime(18797):    at android.app.ActivityThread.access$1300(ActivityThread.java:204)
E/AndroidRuntime(18797):    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1674)
E/AndroidRuntime(18797):    at android.os.Handler.dispatchMessage(Handler.java:106)
E/AndroidRuntime(18797):    at android.os.Looper.loop(Looper.java:193)
E/AndroidRuntime(18797):    at android.app.ActivityThread.main(ActivityThread.java:6865)
E/AndroidRuntime(18797):    at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(18797):    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:504)
E/AndroidRuntime(18797):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
E/AndroidRuntime(18797): Caused by: java.io.UncheckedIOException: Error reading bundled metadata. Commonly this is caused by using a wear build on a phone or vice versa.
E/AndroidRuntime(18797):    at bpc.f(PG:54)
E/AndroidRuntime(18797):    at bxm.a(PG:9)
E/AndroidRuntime(18797):    at bxl.b(PG:346)
E/AndroidRuntime(18797):    at ila.b(PG:16)
E/AndroidRuntime(18797):    at com.google.android.apps.speech.tts.googletts.service.GoogleTtsService.onCreate(PG:131)
E/AndroidRuntime(18797):    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3589)
E/AndroidRuntime(18797):    ... 8 more
E/AndroidRuntime(18797): Caused by: java.io.FileNotFoundException: voices-list-wear-dsig.pb
E/AndroidRuntime(18797):    at android.content.res.AssetManager.nativeOpenAsset(Native Method)
E/AndroidRuntime(18797):    at android.content.res.AssetManager.open(AssetManager.java:744)
E/AndroidRuntime(18797):    at android.content.res.AssetManager.open(AssetManager.java:721)
E/AndroidRuntime(18797):    at bpc.f(PG:12)
E/AndroidRuntime(18797):    ... 13 more
MrCsabaToth commented 1 month ago

Note, that the Speech Recognition & Synthesis package is installed on the watch by default (https://www.apkmirror.com/apk/google-inc/google-text-to-speech-engine/)

MrCsabaToth commented 1 month ago

I installed Android Accessibility Suite and Voice Access apps from Google LLC

Then tried to discover any place where language can be configured, such as:

Then I restarted and the exception doesn't come now. The question is of the service will work. It might be that somehow I was able to install a TTS engine with any of those two apps, however even before that I saw both input and output sides and English was there at least for each direction! We'll see.