[Asterisk-Users] Looping Problem With Call Forwards - Do you
have comments on my solution?
Adam Goryachev
mailinglists at websitemanagers.com.au
Wed Jan 4 04:22:05 MST 2006
On Tue, 2006-01-03 at 12:42 -0600, Brent Torrenga wrote:
> I use IP Kall to forward my missed cell phone calls to. This way, if my
> phone is off, or out of a service area, calls will go to my * box.
> Concurrently, all incoming calls to my * box cause it to dial my local
> extensions at home, my extension at work, and my cell phone via NuFone.
>
> Problem: A loop can be created if my cell phone is not on. Say a call comes
> into my * box, it uses NuFone to call my cell, my cell forwards the call to
> IP Kall, IP Kall to my * box...... You see.
>
Why not simply something like this:
exten => 123,n,Set(GROUP()=Mobile) ; Set group to the mobile
exten => 123,n,GotoIf($[ ${GROUP_COUNT(${mychan})} > 1 ]?next)
exten => 123,n(next),Goto(context,exten,priority) ; Skip over calling
your mobile since there is already another call in progress, ie, send to
VM, or retry your home/office/etc...
exten => 123,n,Dial(IAX2/provider/mobilenum)
On the next line, you could also just play some MoH and wait for 10
seconds, then loop around and try again, etc... but then you are
probably better off using the queue system with agents ...
Hope this helps somewhat...
Regards,
Adam
More information about the asterisk-users
mailing list