Hi,
I am working on asterisk 13. I want to use the Disa to provide the dial-tone and allow the user to enter the number when a specific extension is dialed.
Also, I am setting up the system with the SLA. The I want to use disa for SLA station also. In the following example, if the user presses the line key then it should be called the disa and allow the user to dial the number(phone number/multiple digits) or if user dial 1111 then the user should hear the dial tone and should be able to enter the dial the number.
In the following setup, extension/station 8883 is on an IP phone and 8884 is on another IP phone.
Following are my asterisk config files. Please check the issues/question in the bottom.
–> sla.conf
[general]
attemptcallerid = yes
[user1Line]
type = trunk
attemptcallerid = yes
device = Local/disa@outbound1
barge=yes
[user2Line]
type = trunk
attemptcallerid = yes
device = Local/disa@outbound2
barge=yes
[station](!)
type=station
trunk=user1Line
trunk=user2Line
[8883](station)
device = PJSIP/8883
[8884](station)
device = PJSIP/8884
[8885](station)
device = PJSIP/8885
–> extensions.conf
[user1Line]
exten => s,1,NoOp(Transfering to available line)
same => n,SLATrunk(user1Line);
[user2Line]
exten => s,1,NoOp(Transfering to available line)
same => n,SLATrunk(user2Line);
[outbound1]
exten => disa,1,NoOp(disa1)
same => n,DISA(no-password,line1_outbound)
[line1_outbound]
exten => _[+*0-9].,NoOp(outbound-line1)
same => n,Dial(PJSIP/${EXTEN}@user1,60,r)
[outbound2]
exten => disa,1,NoOp(disa2)
same => n,DISA(no-password, line2_outbound)
[line2_outbound]
exten => _[+*0-9].,NoOp(outbound-line2)
same => n,Dial(PJSIP/${EXTEN}@user2,60,r)
[sla_stations]
exten => 8883,1,SLAStation(8883)
exten => 8883_user1Line,hint,SLA:8883_user1Line
exten => 8883_user1Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8883_user1Line)
exten => 8883_user2Line,hint,SLA:8883_user2Line
exten => 8883_user2Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8883_user2Line)
exten => 8884,1,SLAStation(8884)
exten => 8884_user1Line,hint,SLA:8884_user1Line
exten => 8884_user1Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8884_user1Line)
exten => 8884_user2Line,hint,SLA:8884_user2Line
exten => 8884_user2Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8884_user2Line)
exten => 8885,1,SLAStation(8885)
exten => 8885_user1Line,hint,SLA:8885_user1Line
exten => 8885_user1Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8885_user1Line)
exten => 8885_user2Line,hint,SLA:8885_user2Line
exten => 8885_user2Line,1,NoOp(caller id ${CALLERIDNUM})
same => n,SLAStation(8885_user2Line)
exten => 1111,1,NoOp(disa2 from the sla_station)
same => n,DISA(no-password, line2_outbound)
–> pjsip.conf
[global]
type=global
keep_alive_interval=20
endpoint_identifier_order=username,ip,anonymous
[simple]
type=transport
protocol=udp
bind=0.0.0.0
tos=cs7
cos=7
[simpletrans]
type=transport
protocol=tcp
bind=0.0.0.0:5060
tos=cs7
cos=7
local_net=192.168.145.0/24
external_media_address=71.225.187.142
external_signaling_address=71.225.187.142
[user1]
type=registration
outbound_auth=user1
outbound_proxy=sip:abcd.sip.com\;transport=tcp
transport=simpletrans
line=yes
retry_interval=60
endpoint=user1
expiration=600
max_retries=240
server_uri=sip:abcd.sip.com\;transport=tcp
client_uri=sip:user1@abcd.sip.com\;transport=tcp
[user1]
type=auth
auth_type=userpass
password=1234567890
username=user1
[user1]
type=aor
remove_existing=yes
contact=sip:abcd.sip.com\;transport=tcp
[user1]
type=endpoint
tos_audio=cs7
cos_audio=7
direct_media=no
force_rport=yes
context=user1Line
rewrite_contact=yes
transport=simpletrans
mailboxes=999@vm_setup
disallow=all
allow=ulaw,h263,h264
from_user=user1
from_domain=abcd.sip.com\;transport=tcp
aors=user1
outbound_auth=user1
[user2]
type=registration
outbound_auth=user2
outbound_proxy=sip:abcd.sip.com\;transport=tcp
transport=simpletrans
line=yes
retry_interval=60
endpoint=user2
expiration=600
max_retries=240
server_uri=sip:abcd.sip.com\;transport=tcp
client_uri=sip:user2@abcd.sip.com\;transport=tcp
[user2]
type=auth
auth_type=userpass
password=0987654321
username=user2
[user2]
type=aor
remove_existing=yes
contact=sip:abcd.sip.com\;transport=tcp
[user2]
type=endpoint
tos_audio=cs7
cos_audio=7
direct_media=no
force_rport=yes
context=user2Line
rewrite_contact=yes
transport=simpletrans
mailboxes=999@vm_setup
disallow=all
allow=ulaw,h263,h264
from_user=user2
from_domain=abcd.sip.com\;transport=tcp
aors=user2
outbound_auth=user2
[8883]
type=endpoint
transport=simple
context=sla_stations
send_pai=yes
send_rpid=yes
disallow=all
tos_audio=cs7
cos_audio=7
rewrite_contact=yes
dtmf_mode=rfc4733
allow=ulaw,h263,h264
mailboxes=999@vm_setup
auth=8883
aors=8883
[8883]
type=auth
auth_type=userpass
password=abcdabcdabcd1
username=8883
[8883]
type=aor
max_contacts=2
[8884]
type=endpoint
transport=simple
context=sla_stations
send_pai=yes
send_rpid=yes
disallow=all
tos_audio=cs7
cos_audio=7
rewrite_contact=yes
dtmf_mode=rfc4733
allow=ulaw,h263,h264
mailboxes=999@vm_setup
auth=8884
aors=8884
[8884]
type=auth
auth_type=userpass
password=abcdabcdabcd2
username=8884
[8884]
type=aor
max_contacts=2
[8885]
type=endpoint
transport=simple
context=sla_stations
send_pai=yes
send_rpid=yes
disallow=all
tos_audio=cs7
cos_audio=7
rewrite_contact=yes
dtmf_mode=rfc4733
allow=ulaw,h263,h264
mailboxes=999@vm_setup
auth=8885
aors=8885
[8885]
type=auth
auth_type=userpass
password=abcdabcdabcd3
username=8885
[8885]
type=aor
max_contacts=2
Issues/Questions:
- If I dial “1111” or “8885_user1Line” or “8885_user2Line”, the call is getting connected to the disa and I ma hearing the dial-tone. However, as soon as I press any number, the call is getting hung up.
- why Disa is hanging up the call after the first DTMF?
- How can I allow Disa to handle multiple digits(DTMF) which I can use with Dial() and make a call to that number?
- If I don’t press anything during that dial tone then Disa will wait for 11-12 seconds and it will hang up the call after that. How can I increase the wait time?
- When I dial the “8883_user1Line” or “8883_user2Line” or “8884_user1Line” or “8884_user2Line” from the phones, I am getting “603 Decline” error on the phones and it is not connecting to the Disa at all.
Any help would be appreciated.
Thanks.