<extension name="MyExtension">
<condition field="destination_number" expression="9005">
<action application="answer"/>
<action application="play_and_get_digits" data="4 16 3 7000 # phrase:MyPrompt phrase:My_invalid_entry case_number \d+" />
<action application="playback" data="phrase:wait_msg" />
<action application="sched_broadcast" data="+0 playback::/tmp/WPJ_MUSIC_QUEUE_4.wav"/>
<action application="lua" data="get_customer_info.lua ${case_number}" />
</condition>
</extension>
The music only plays after the Lua script exits. I played around with the timer value, but that did not help either. Any other ideas?
Thanks
JP
On Fri, Jan 25, 2013 at 1:22 AM, Avi Marcus
<avi@avimarcus.net> wrote:
ESL gives you more control, especially to execute things in parallel.
If you want to do it within FS, that's a little more complicated, since most things are sequential.
However, if you use the async APIs, then I think it could work:
1)
sched_broadcast -- schedule the playback of your file on the UUID of the channel, for +0, meaning now.
2) run your lua script
3) Then stop (break) the playback on that uuid:
break4) Continue with your execution.
Please wikify your results and let us know how that works out!
_________________________________________________________________________
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
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