B.42. Festival()

Uses the free Festival text-to-speech (TTS) engine to read text to the caller.
Festival(text[,keys])
Connects to the locally running Festival server (which must be installed separately), sends it the specified text and plays the resulting audio back to the caller. If keys are defined, pressing of the defined keys will interrupt playback and return the value of the key depressed; if any is provided as the value to keys, all keys will be recognized and the call will be passed to the appropriate extension in the dialplan.
Festival must be started before Asterisk, and the channel must be answered with Answer(), in order for this application to work..
exten => 123,1,Answer()
exten => 123,n,Festival('Hello World',#)
As an alternative to the application Festival(), you may also use the System() command to call Festival's command-line program text2wave and play back the resulting audio stream with Background() or Playback(), like so (for example only; pay attention to pathnames!):
exten => 123,1,Answer()
exten => 123,n,System(echo 'Hello World' | text2wave -o sound.wav -otype wav -)
exten => 123,n,Background(sound)

Note

Internal help for this application in Asterisk 1.4:
  -= Info about application 'Festival' =- 

[Synopsis]
Say text to the user

[Description]
  Festival(text[|intkeys]):  Connect to Festival, send the argument, get back the waveform,play it to the user, allowing any given interrupt keys to immediately terminate and return
the value, or 'any' to allow any number back (useful in dialplan)
diff output to internal help in Asterisk 1.2:
- none - 
See also
contrib/README.festival