[asterisk-users] WaitForSilence Problems

Nicholas Blasgen nicholas at blasgen.com
Thu Jul 17 15:11:36 CDT 2008


I'm trying to write an application for using after an agent has decided the
person on the other end is an answering machine and would like to drop in a
message automaticly.  When I'm testing this using my own voice as an
aswering machine, WaitForSilence works correctly and returns only after a
decent delay.  But when I hit my real cell phone's voice mail and transfer
the call to the auto-message system, WaitForSilence returns after the given
delay without waiting for it to finish.  I'm thinking this has something to
do with the audio level and it not being enough for WaitForSilence to
register.  But that really makes no sense.

    -- Executing [360445792 at dropin:1] Wait("SIP/vitelity-09e4f7c8", "1") in
new stack
    -- AGI Script Executing Application: (PLAYBACK) Options: (beep)
    -- <SIP/vitelity-09e4b8c8> Playing 'beep' (language 'en')
    -- Executing [360445792 at dropin:2]
WaitForSilence("SIP/vitelity-09e4f7c8", "2500") in new stack
    -- Waiting 1 time(s) for 2500 ms silence with 0 timeout
    -- AGI Script Executing Application: (PLAYBACK) Options: (beep)
    -- <SIP/vitelity-09e4b8c8> Playing 'beep' (language 'en')
    -- Exiting with 2500ms silence >= 2500ms required
    -- Executing [360445792 at dropin:3] Playback("SIP/vitelity-09e4f7c8",
"recordings/360445792") in new stack
    -- <SIP/vitelity-09e4f7c8> Playing 'recordings/360445792' (language
'en')
    -- AGI Script Executing Application: (PLAYBACK) Options: (beep)
    -- <SIP/vitelity-09e4b8c8> Playing 'beep' (language 'en')
    -- Executing [360445792 at dropin:4] Hangup("SIP/vitelity-09e4f7c8", "") in
new stack

[dropin]
exten => _X.,1,Answer()
exten => _X.,n,Wait(1)
exten => _X.,n,WaitForSilence(2500)
exten => _X.,n,Playback(recordings/${EXTEN})
exten => _X.,n,Hangup()

I added the Wait(1) and Answer() just as an added thing, but they shouldn't
be needed.  Anyone have a suggestion?

-- 
Nicholas Blasgen
nicholas at blasgen.com
408.497.9796 (c)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20080717/a752a197/attachment.htm 


More information about the asterisk-users mailing list