Text-To-Speech


Last Updated:

  1. GiantKruemel

    GiantKruemel Member This Topic's Starter

    Joined:
    Feb 13, 2009
    Messages:
    6
    Likes Received:
    0
    Hello everybody.
    I'm trying to program an application that uses Text-To-Speech functionally.
    I followed the tutorial at this page:
    http://eyes-free.googlecode.com/svn/trunk/documentation/tutorial/tutorial.html

    (Of course I didn t forget to run the virtual phone with the virtual sdcard and to add the TTS library)
    Here is the code:

    Code (Text):
    1.  
    2. package wolf.android.hello;
    3.  
    4. import com.google.tts.TTS;
    5.  
    6. import android.app.Activity;
    7. import android.os.Bundle;
    8.  
    9. public class hello extends Activity {
    10.     private TTS myTts;
    11.    
    12.     /** Called when the activity is first created. */
    13.     @Override
    14.     public void onCreate(Bundle savedInstanceState) {
    15.         super.onCreate(savedInstanceState);
    16.         setContentView(R.layout.main);
    17.         myTts = new TTS(this, ttsInitListener, true);
    18.     }
    19.    
    20.     private TTS.InitListener ttsInitListener = new TTS.InitListener() {
    21.         public void onInit(int version) {
    22.           myTts.speak("Hello world", 0, null);
    23.         }
    24.       };
    25. }
    26.  
    When I start this application, than a message comes up: "This application can talk using the text-to-speech (TTS) libary. Please install the TTS."I clicked on "install the TTS" And the Exception "Sorry! The application Hello you! (process wolf.android.hello) has stopped unexpectedly. Please try again." came up.

    Can someone help me with this? I am trying to fix this since monday and its still not working.

    MFG Da Wolf
     

    Advertisement
  2. GiantKruemel

    GiantKruemel Member This Topic's Starter

    Joined:
    Feb 13, 2009
    Messages:
    6
    Likes Received:
    0
    its working...
     
  3. mbreezy

    mbreezy New Member

    Joined:
    Feb 23, 2009
    Messages:
    3
    Likes Received:
    0
    How did you get this working? I'm encountering the same problem.
     
  4. mbreezy

    mbreezy New Member

    Joined:
    Feb 23, 2009
    Messages:
    3
    Likes Received:
    0
    Nevermind... I installed the APK for the TTS; however, I'm still not hearing anything. Is it downloading the voice?
     
  5. Jenish

    Jenish New Member

    Joined:
    Sep 11, 2009
    Messages:
    1
    Likes Received:
    0
    Me didn hear nythg...
    I have done everythg.... but didn knw y i cant hear nythg
    am new to Android...
    thnx in advance...:)
     
  6. misulakee

    misulakee New Member

    Joined:
    Mar 30, 2011
    Messages:
    1
    Likes Received:
    0

Share This Page

Loading...