[asterisk-users] Dial timeout to cell phones
Mark G. Thomas
Mark at Misty.com
Tue Sep 2 14:42:58 CDT 2008
Hi,
On Tue, Sep 02, 2008 at 03:22:21PM -0400, John Novack wrote:
>
> Steve Repo wrote:
> > Hello,
> >
> > I'm new to asterisk and i'm having a really good time configuring it.
> >
> > I'd like to VoIP-to-PSTN call my SIP number (${MYSIP}) first and then
> > my cell phone (123456) and then finally to my voicemail.
> >
> > Here's my dialplan.
> >
> > exten => s,1,Answer()
> > exten => s,n,Dial(${MYSIP},20)
> > exten => s,n,Dial(Zap/g0/123456,10)
> > exten => s,n,Voicemail(${MYSIP}@default)
> > exten => s,n,Hangup()
> >
> > When I receive calls, my IP phone (SIP) rings for 20 seconds as
> > expected. However, asterisk does not terminate calls to my cell phone
> > after 10 seconds and keeps ringing.
> >
> > The call to my cell phone is then answered by cell phone voicemail
> > instead of asterisk voicemail.
> >
> > Any ideas how to go about this?
> >
> > Thanks!
> > Steve
> >
> Zap channels are considered answered once dialing is complete, so your
> "10" second time fails
> No answer supervision on Zap
>
> John Novack
It was challenging to figure this out, since a lot of the online
examples seem to work differently, depending on older versions of Asterisk.
I wanted to ring my cellphone (via SIP provider) and deskphone (via Zap)
simultaneously, but didn't want the call to end up with the cellphone
voicemail, so press "1" on my cellphone if I want to accept the call
there. I even see the original caller ID of the inbound caller on my
cellphone, since I'm out-dialing via a SIP provider.
[inbound]
exten => 2155551212,1,Playtones(ring) ; play fake ring so caller doesn't wonder
exten => 2155551212,n,Dial(Zap/g10&local/101 at internals,,) ; ring FXS and cell
; http://www.voip-info.org/wiki/index.php?page=Asterisk+Local+channels
;
[internals]
exten => 101,1,Dial(${MARKCELL},30,tM(screen)) ; play message before connecting
; http://www.voip-info.org/wiki/view/Asterisk+tips+findme
; play message to cellphone before connecting inbound call
; http://lists.digium.com/pipermail/asterisk-dev/2005-June/013598.html
;
[macro-screen]
exten => s,1,Wait(0.5)
exten => s,n,Read(ACCEPT,inbound,1,,1,20)
exten => s,n,GotoIf($["${ACCEPT}" = "1"]?yes:no)
exten => s,n(yes),Background(connecting)
exten => s,n,Goto(end) ; Continue on in dialplan to bridge the call
exten => s,n(no),Set(MACRO_RESULT=CONTINUE) ; Hangup the called party and continue on in the dialplan
exten => s,n(end),NoOp
--
Mark G. Thomas (Mark at Misty.com)
More information about the asterisk-users
mailing list