Situation With Ivr And Four-channel Gateway

Home » Asterisk Users » Situation With Ivr And Four-channel Gateway
Asterisk Users 8 Comments

Hi list, I need your help ,I have an incoming call x the ivr and the operator takes the call. ext “101” , If a second call reenters and the operator is talking, I want to send to the extension 102 I use the Variable DIALSTATUS , but not working

check IVR

[IVRINMA]

exten => s,1,Wait(1)
exten => s,n,Set(CHANNEL(language)=es)
same=> n,Set(TIMEOUT(digit)=4)
same=> n,Set(TIMEOUT(response)=5)
same=> n,Wait(1)
same=> n,Background(/tmp/ivr/menu)
same=> n,WaitExten(5)
exten => 0,1,Playback(pls-wait-connect-call)
exten => 0,n,Goto(operadora,101,1)
exten => _10[1-3],1,Dial(SIP/${EXTEN},40,t)
same=> n,Hangup exten => i,1,Playback(invalid)
same=> n,Goto(IVRINMA,s,2)
exten=> t,1,Dial(SIP/101,38,t)
exten=> t,n,GotoIf($[“${DIALSTATUS}” = “BUSY”]?2,1:)
exten => 2,1,Dial(SIP/102,38,t)
same=> n,Hangup()

## the second option, if possible ###

I have a gw wiht 4 port gsm , my provider gives me 4 lines and one of them is the main , the problem is that all my incoming calls using this number and is always busy , and the other three are always free, it is possible that the call is transferred to another channel?

Channel 1 : XXXXXXX1 “Main Number”
Channel 2 : XXXXXXX2 “other”
Channel 3 : XXXXXXX3 “other”
Channel 4 : XXXXXXX4 “other”

regardss

8 thoughts on - Situation With Ivr And Four-channel Gateway

  • You just need to use call groups.

    In your chan_extra.conf (if it’s an OpenVox) or chan_dahdi.conf, add something like
    group=1
    to the definition for each span.

    Now in the [globals] section of your dialplah, have something like
    MOBILE=EXTRA/r1
    for an OpenVox card, or
    MOBILE

  • 2015-02-27 10:25 GMT-06:00 A J Stiles :
    apology, put the gateway was sangoma but is a openvox ,

    all my outgoing calls out for this context:

    [my-mobile-out]

    exten => _NXXXXXXX,n,Dial(SIP/1003/${EXTEN},55,rT)
    exten => _NXXXXXXX,n,Dial(SIP/1004/${EXTEN},55,rT)
    exten => _NXXXXXXX,n,Dial(SIP/1001/${EXTEN},55,rT)
    exten => _NXXXXXXX,n,Dial(SIP/1002/${EXTEN},55,rT)
    exten => _NXXXXXXX,n,Playback(all-circuits-busy-now)
    exten => _NXXXXXXX,n,Hangup()

    my main number is registered on “1002” channel gsm 1

    the problem is that my pbx all incoming calls using only the channel gsm 1 , the idea is that an incoming call to channel 1 is passed to channel 2

    regardss.

  • Ah. *Incoming* calls are not something that is within your control; they have already been routed onto a line by your telco. So you will need to speak to someone at your telco about doing this.

    As a temporary measure, you could try setting up divert-on-busy so SIM1
    diverts to SIM2, SIM2 diverts to SIM3, SIM3 diverts to SIM4 and SIM4 diverts to SIM1. You can do this with specially-crafted Dial() statements, or by temporarily inserting the SIMs in an old mobile phone. See your telco’s website for details of setting up call diversion.

  • 2015-03-02 3:44 GMT-06:00 A J Stiles :

    Hi Aj, I call to telco and say they can not in GSM, only on lines are analogous

    With asterisk or the openvox gw?

    or by

    these guys do not help much! .

    the ivr worked perfect with DEVICE_STATE , thank john!

    exten => t,1,ExecIf($[ ${DEVICE_STATE(SIP/${EXTEN})} = INUSE ]?Busy)

    exten => t,n,Dial(SIP/110,38,t)

    same=> n,Dial(SIP/162,40,t)

    same=> n,Hangup()

    thnk for all help.