Not speaking string in android phone Emulator

  • Replies:1
Hiren Sangani
  • Forum posts: 1

Jul 7, 2013, 5:04:46 PM via Website

Hi all,

I am brand new to the android world. I made a simple calculator app and a splash screen which make sound while start the splash screen and pressing the buttons of calculator. I ran this app on Emulator and everything went well but when I download .apk to my HTC Desire S then the calculator works and they make sound but I added SpeechToText object which does speak string when I pressed some of the buttons . For example I put button sound on + then this button function well but it doesn't speak..

String textA="addition";
t2s= new TextToSpeech(MainActivity.this,new TextToSpeech.OnInitListener() {

@Override
public void onInit(int status) {
// TODO Auto-generated method stub
if(status!=TextToSpeech.ERROR){
t2s.setLanguage(Locale.US);
}

add.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
// TODO Auto-generated method stub
ButtonAdd.start();

t2s.speak(textA, TextToSpeech.LANG_AVAILABLE, null);
counter++;
display.setText("Total is" + counter);
}


Please help me out..

Thanks,
Hiren

— modified on Jul 7, 2013, 5:05:19 PM

Reply
Alina Billingsley
  • Forum posts: 5

Dec 13, 2013, 7:38:43 AM via Website

Can anyone give me clear idea of what eclipse is and how to install android emulator?

Reply