“pico TTS引擎已停止”错误

时间:2016-03-28 21:52:04

标签: android text-to-speech

我正在使用TextToSpeech编写代码。它在整个代码中运行良好,但是,每次我退出代码时,它都会给出错误消息“不幸的是,pico TTS引擎已停止。”这只会在我退出代码时发生。我想知道为什么会发生这种情况谢谢。

3 个答案:

答案 0 :(得分:1)

每当我退出代码或每次拨打textToSpeech.shutdown();

时,我都会收到此消息

我通过删除我的AVD(Android虚拟设备Nexus_6_API_23)并创建一个新问题来解决这个问题。新的AVD工作没有给出任何错误消息。

显然这是我的AVD的问题,而不是我的代码或TTS引擎的问题。

答案 1 :(得分:1)

我遇到了同样的问题。每当我改变活动或退出程序时,我都会得到“pico TTS Engine已停止"。我将api从23更改为24并使用了android 7.0,错误已经消失。

答案 2 :(得分:0)

请在this link上查看问题

  
pytest -s import
CTS cases fail due to NE in SVOX TTS library

Failed CTS cases:
android.speech.tts.cts.TextToSpeechTest#testSpeak
android.speech.tts.cts.TextToSpeechTest#testSpeakStop
android.speech.tts.cts.TextToSpeechTest#testSynthesizeToFile

We can also reproduce this NE by following steps:
1. Go to Accessibility Settings
2. Select Text to speech output
3. Click play

Analysis: Exception occurs due to calculation of
picokpr_getAttrValArrInt32(...) is incorrect. The logic here intends
to clear the MSB and return the rest of the bits. We found if library
compiled in Android N environment the result of comparison operation
is different from library compiled in Android O environment. In
Android O, actual returne value doesn't process the value and returns
as it is. This causes invalid pointer access and hence native
exception due to segmentation fault.

Solution: Changed to use bitwise shift instead.

Bug: 64204643 Test: After applying this patch, CTS cases can pass and
exception can be fixed.

Change-Id: Ife3137225ecf9667df62321472420fab6ab88d2e