it's playing twice because of the second accept -- that's what it plays upon invalid entry. But you don't want any message on non-match.You might want
getdigits, a simpler way to get input without retry options.
Wait, are you using this for confirm of pickup for hunting to mobiles?
Doesn't
http://wiki.freeswitch.org/wiki/Variable_group_confirm_file work for you? It seems to fit my use case.
-Avi
On Thu, Jun 14, 2012 at 12:26 PM, Alex Lake
<alex@digitalmail.com> wrote:
I have the following in a lua script:
session:streamFile(whisper)
dtmf = session:playAndGetDigits(1,1,1,5000,"#",accept,accept,"\\d+")
The idea is that the caller hears "Call for Alex of Wibble
Corp"..."Press 1 to accept" and then he has 5s to press 1, otherwise
it's assumed that the call has gone to mobile voicemail.
What seems to be happening is:
the caller hears "Call for Alex of Wibble Corp"..."Press 1 to accept"
<pause 5s> "Press 1 to accept" <immediate hangup>
(I'm surprised that it says it twice, and ignores the <timeout> attribute)
Actually, I wouldn't mind something that went
"Call for Alex of Wibble Corp"..."Press 1 to accept" <pause 3s> "Press 1
to accept" <pause 3s> <hangup>
But telling the user to press 1 and IMMEDIATELY hanging up seems wrong!
_________________________________________________________________________
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