There is something wrong with the speak_text.py file.
It doesn’t work. It merely takes in the input and prints the output.
It does not speak. The speak_count.py file works perfectly. I suspect its something wrong with cmd-end or cmd_out. If someone could fix this that’d be great. I’m still trying to figure it out
Here is my version of speak_text.py and speak_count.py that fix the problems, allow use without sudo, provide greater protection from quotes and apostrophes, and enables using espeak options to set speed and voice.
I made a speak.py module to generalize using TTS in my robot code as:
import speak
text = "I am a vociferous talker, but I can't hear myself speaking"
speak.say( text )
Hi Cleoqc,
I am a bit late in the game but I also have the same problem as amkhan. I ran the Speak_text.py which did not output my text word. It did write the sound file to the desktop but did not play it. If I type aplay /usr/share/sounds/alsa/* that will play the word ‘front center’. If I write espeak “Hello World” it does not say anything but writes a lot of errors related to the Unknown PCM card and many other errors. Can you help ?
Would be nice if the old program on Github had a comment to inform that the espeak-ng is the latest or maybe I did not see it since relatively new user on Github.