[asterisk-users] StopPlayTones() after first digit?
Jack Bates
ms419 at freezone.co.uk
Mon Jan 25 20:16:35 CST 2010
I configured our SIP gateway to automatically dial extension "s" when a
phone is picked up. I want Asterisk to play a dial tone, wait for an
extension to be dialled, and hangup on timeout
This works great, but I also want Asterisk to *stop* playing the dial
tone after the first digit is pressed
So far my extensions.conf contains,
[internal]
exten => s,1,Answer
exten => s,n,PlayTones(dial)
exten => s,n,WaitExten
How can I continue playing a dial tone as long as a digit isn't pressed
(and TIMEOUT() hasn't expired) - but stop playing the dial tone as soon
as the first digit is pressed?
I think the Background() application works like this - it stops playing
as soon as the first digit is pressed - it seems PlayTones() works
differently?
More information about the asterisk-users
mailing list