Background not waiting


I’ve just run into a problem using TIMEOUT(digit) and Background.

I have the following configuration:

exten => 7172332,1,Answer()
exten => 7172332,n,Set(TIMEOUT(digit)=2)
exten => 7172332,n,Background(Silence/1)
exten => 7172332,n,Background(no-answer)
exten => 7172332,n,Goto(severnrd,2,1)
exten => 7172332,n,Congestion()

While it is executing Background If I were to type for example 1234 on my phone keypad, Asterisk only gets 1, as if it is ignoring the timeout setting all together. It then just rushes to extn ‘i’.

I have used the same thing in other contexts but in this one it just doesn’t work.

Any pointers??



You need a line like this after each of the background lines with asterisk 1.4 or later. I ran into a similar problem when upgrading from asterisk 1.2:

exten => 7172332,n,WaitExten(y)

where y is the time to wait in ms.

Your digit timeout may be too brief, so all it detects is “1”, which it then determines as invalid. Try increasing the timeout to 10 seconds to test this.