You should probably be using this instead of sleep:
<action function="play-file" data="silence_stream://1000"/>

This may be FUD, but I recall that sleep could have unintended side-effects because it doesn't provide an RTP stream... while this is playing silence.

-Avi

On Thu, Jun 21, 2012 at 11:12 AM, Alex <alex@thewinelake.com> wrote:
Having got to grips with phrases, I can now see that there is a cheating
way to do this, which maybe should be put in the wiki?

Essentially, the idea is to have file
<freeswitch>/conf/lang/en/simple/simplesay.xml:

<include>
  <macro name="say">
    <input pattern="(.*)">
      <match>
        <action function="execute" data="sleep(1000)"/>
        <action function="speak-text" data="$1"/>
      </match>
    </input>
  </macro>


Modify <freeswitch>/conf/lang/en/en.xml to include:

<X-PRE-PROCESS cmd="include" data="simple/simplesay.xml"/>

If you don't use cepstral, edit the first line to be:

<language name="en" say-module="en"
sound-prefix="$${sounds_dir}/en/us/callie" tts-engine="flite"
tts-voice="kal">


Then in a lua script, you can do something like this:

destnum = session:playAndGetDigits(3, 20, 3, 5000, "#*",
"phrase:sa:"..sayWhatFirst, "", "\\d+")



_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

FreeSWITCH-powered IP PBX: The CudaTel Communication Server
http://www.cudatel.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://wiki.freeswitch.org
http://www.cluecon.com

Join Us At ClueCon - Aug 7-9, 2012

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org