Saturday, January 9, 2010

How to fix the error: "Linux: can't open /dev/dsp" while trying to use Festival

The error:

$ festival --tts read.txt
Linux: can't open /dev/dsp


The fix:
Create file .festivalrc in the home directory of the user and paste this in it:

(Parameter.set 'Audio_Command "aplay -q -c 1 -t raw -f s16 -r $SR $FILE")
(Parameter.set 'Audio_Method 'Audio_Command)

Then, try the "festival --tts read.txt" command again, the error should be gone, and you should hear the synthesized text to speech stream.


Share

No comments:

Post a Comment