WaitForSilence() — Waits for a specified amount of silence
Waits for repeat
instances of
silencerequired
milliseconds of silence. If
repeat
is omitted, the application waits for
a single instance of silencerequired
milliseconds of silence.
If the timeout
option is specified,
this application will return to the next priority in the dialplan after
the specified number of seconds, even if silence has not been
detected.
Please use the timeout
with caution,
as it may defeat the purpose of this application, which is to wait
indefinitely until silence is detected on the line. You may want to
set the timeout to a high value only to avoid an infinite loop in
cases where silence is never detected.
This applications sets a channel variable named WAITSTATUS
to either SILENCE
or TIMEOUT
.
; wait for three instances of 300 ms of silence
exten => 123,WaitForSilence(300,3)