WaitForRing()

Waits the specified number of seconds for a ring signal.

        
          WaitForRing(timeout)
        
      

Waits a maximum of timeout seconds for a ring signal, which is only treated as valid until the second ring has completed.

Returns 0 on success, or -1 if the channel is hung up.

; Wait 5 seconds for ring, then send DTMF:
exten => 123,1,Answer()
exten => 123,n,WaitForRing(5)
exten => 123,n,SendDTMF(1234)
[Note]

Internal help for this application in Asterisk 1.4: 

  -= Info about application 'WaitForRing' =- 

[Synopsis]
Wait for Ring Application

[Description]
  WaitForRing(timeout)
Returns 0 after waiting at least timeout seconds. and
only after the next ring has completed.  Returns 0 on
success or -1 on hangup

diff output to internal help in Asterisk 1.2: 

- none -