[Freeswitch-users] playAndGetDigits working as designed?

Alex Lake alex at digitalmail.com
Thu Jun 14 13:26:52 MSD 2012


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!



Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list