Outgoing call not going

I am new to Asterisk. I created 4 extensions 1010,1020,1030,1040. When I call at any extension from another extension, both are softphones, it is working fine. But when I make a call from an extension to outside world it is not going. I have Sangoma Technologies Corp. A200/Remora FXO/FXS Analog AFT card (lspci is showing) , Linux version: CentOS 7.3.16.11 (Core), Asterisk 13.14.0 running.

Please help me out to make a call out and make a call in

Thanks in advance

Show your configs for Dahdi, wanpipe and the cli output when it fail.

Wanrouter summary –
[root@localhost ~]# wanrouter summary

Configuration File Summary in : /etc/wanpipe/

Device Protocol Type Cpu/Io Slot/Irq Bus State

wanpipe1 WAN_AFT_TE1 PCI A 4 37 Connected
wanpipe2 WAN_AFT_TE1 PCI A 4 37 Disconnected

------------------------wanpipe1.conf in /etc/wanpipe/wanpipe1.conf-------------------------------
#================================================

WANPIPE1 Configuration File

#================================================

Date: Wed Dec 6 20:29:03 UTC 2006

Note: This file was generated automatically

by /usr/local/sbin/setup-sangoma program.

If you want to edit this file, it is

recommended that you use wancfg program

to do so.

#================================================

Sangoma Technologies Inc.

#================================================

[devices]
wanpipe1 = WAN_AFT_TE1, Comment

[interfaces]
w1g1 = wanpipe1, , TDM_VOICE, Comment

[wanpipe1]
CARD_TYPE = AFT
S514CPU = A
CommPort = PRI
AUTO_PCISLOT = NO
PCISLOT = 4
PCIBUS = 37
FE_MEDIA = E1
FE_LCODE = HDB3
FE_FRAME = NCRC4
FE_LINE = 1
TE_CLOCK = NORMAL
TE_REF_CLOCK = 0
TE_SIG_MODE = CCS
TE_HIGHIMPEDANCE = NO
TE_RX_SLEVEL = 430
HW_RJ45_PORT_MAP = DEFAULT
LBO = 120OH
FE_TXTRISTATE = NO
MTU = 1500
UDPPORT = 9000
TTL = 255
IGNORE_FRONT_END = NO
TDMV_SPAN = 1
TDMV_DCHAN = 16
TE_AIS_MAINTENANCE = NO #NO: defualt YES: Start port in AIS Blue Alarm and keep line down
#wanpipemon -i w1g1 -c Ttx_ais_off to disable AIS maintenance mode
#wanpipemon -i w1g1 -c Ttx_ais_on to enable AIS maintenance mode
TDMV_HW_DTMF = YES # YES: receive dtmf events from hardware
TDMV_HW_FAX_DETECT = NO # YES: receive fax 1100hz events from hardware
HWEC_OPERATION_MODE = OCT_NORMAL # OCT_NORMAL: echo cancelation enabled with nlp (default)
# OCT_SPEECH: improves software tone detection by disabling NLP (echo possible)
# OCT_NO_ECHO:disables echo cancelation but allows VQE/tone functions.
HWEC_DTMF_REMOVAL = NO # NO: default YES: remove dtmf out of incoming media (must have hwdtmf enabled)
HWEC_NOISE_REDUCTION = NO # NO: default YES: reduces noise on the line - could break fax
HWEC_ACUSTIC_ECHO = NO # NO: default YES: enables acustic echo cancelation
HWEC_NLP_DISABLE = NO # NO: default YES: guarantees software tone detection (possible echo)
HWEC_TX_AUTO_GAIN = 0 # 0: disable -40-0: default tx audio level to be maintained (-20 default)
HWEC_RX_AUTO_GAIN = 0 # 0: disable -40-0: default tx audio level to be maintained (-20 default)
HWEC_TX_GAIN = 0 # 0: disable -24-24: db values to be applied to tx signal
HWEC_RX_GAIN = 0 # 0: disable -24-24: db values to be applied to tx signal

[w1g1]
ACTIVE_CH = ALL
TDMV_HWEC = YES
MTU = 8
----------------------------End of file wanpipe1.conf----------------------------------------------------------


----------------------------------- snap shot of sip debug ---------------------------------------------------------
<------------->

<— SIP read from UDP:10.0.0.50:5060 —>
INVITE sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKdfcdc11c59c488325917b0cbb6282e26;rport
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956241 INVITE
Contact: sip:10.0.0.50
Supported: replaces
User-Agent: siplib 3.0.25 Built on Feb 2 2013, 14:44:22
Allow: INVITE, ACK, CANCEL, BYE, OPTIONS, INFO, UPDATE, NOTIFY, REFER
Content-Type: application/sdp
Max-Forwards: 70
Content-Length: 291

v=0
o=Dinstar 2269155 2269156 IN IP4 10.0.0.50
s=-
c=IN IP4 10.0.0.50
t=0 0
m=audio 8112 RTP/AVP 18 0 8 4 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=yes
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
a=ptime:20
<------------->
— (13 headers 14 lines) —
Sending to 10.0.0.50:5060 (NAT)
Sending to 10.0.0.50:5060 (NAT)
Using INVITE request as basis request - 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
No matching peer for ‘10.0.0.5’ from ‘10.0.0.50:5060’

<— Reliably Transmitting (NAT) to 10.0.0.50:5060 —>
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKdfcdc11c59c488325917b0cbb6282e26;received=10.0.0.50;rport=5060
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060;tag=as7a10fa19
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956241 INVITE
Server: FPBX-13.0.192.8(13.14.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm=“asterisk”, nonce="3c390693"
Content-Length: 0

<------------>
Scheduling destruction of SIP dialog ‘4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50’ in 32000 ms (Method: INVITE)

<— SIP read from UDP:10.0.0.50:5060 —>
ACK sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKdfcdc11c59c488325917b0cbb6282e26;rport
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060;tag=as7a10fa19
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956241 ACK
Content-Length: 0

<------------->
— (7 headers 0 lines) —

<— SIP read from UDP:10.0.0.50:5060 —>
INVITE sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKbd594c5e62130c8c62d19f69de909678;rport
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956242 INVITE
Contact: sip:10.0.0.50
Authorization: Digest username="", realm=“asterisk”, nonce=“3c390693”, uri=“sip:444442@10.0.0.5:5060”, response=“67e61284f444499a54e6c2f3fa5bc024”, algorithm=MD5
Supported: replaces
User-Agent: siplib 3.0.25 Built on Feb 2 2013, 14:44:22
Allow: INVITE, ACK, CANCEL, BYE, OPTIONS, INFO, UPDATE, NOTIFY, REFER
Content-Type: application/sdp
Max-Forwards: 70
Content-Length: 291

v=0
o=Dinstar 2269155 2269156 IN IP4 10.0.0.50
s=-
c=IN IP4 10.0.0.50
t=0 0
m=audio 8112 RTP/AVP 18 0 8 4 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=yes
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
a=ptime:20
<------------->
— (14 headers 14 lines) —
Sending to 10.0.0.50:5060 (NAT)
Using INVITE request as basis request - 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
No matching peer for ‘10.0.0.5’ from ‘10.0.0.50:5060’
[2017-06-07 16:59:23] NOTICE[4500][C-0000000c]: chan_sip.c:26179 handle_request_invite: Failed to authenticate device 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71

<— Reliably Transmitting (NAT) to 10.0.0.50:5060 —>
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKbd594c5e62130c8c62d19f69de909678;received=10.0.0.50;rport=5060
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060;tag=as7a10fa19
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956242 INVITE
Server: FPBX-13.0.192.8(13.14.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0

<------------>
Scheduling destruction of SIP dialog ‘4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50’ in 32000 ms (Method: INVITE)

<— SIP read from UDP:10.0.0.50:5060 —>
ACK sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bKbd594c5e62130c8c62d19f69de909678;rport
From: 0909305408 sip:10.0.0.5:5060;tag=abf75ee9188dd36de96098228ac30c71
To: sip:444442@10.0.0.5:5060;tag=as7a10fa19
Call-ID: 4d925558cd5aa8a3a5a0d6bbe225e3b2@10.0.0.50
CSeq: 67956242 ACK
Content-Length: 0

<------------->
— (7 headers 0 lines) —

<— SIP read from UDP:10.0.0.50:5060 —>
INVITE sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK0abb81465a4dcc22bdbfe3fe99dcaf9a;rport
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956242 INVITE
Contact: sip:10.0.0.50
Supported: replaces
User-Agent: siplib 3.0.25 Built on Feb 2 2013, 14:44:22
Allow: INVITE, ACK, CANCEL, BYE, OPTIONS, INFO, UPDATE, NOTIFY, REFER
Content-Type: application/sdp
Max-Forwards: 70
Content-Length: 291

v=0
o=Dinstar 2270656 2270657 IN IP4 10.0.0.50
s=-
c=IN IP4 10.0.0.50
t=0 0
m=audio 8028 RTP/AVP 18 0 8 4 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=yes
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
a=ptime:20
<------------->
— (13 headers 14 lines) —
Sending to 10.0.0.50:5060 (NAT)
Sending to 10.0.0.50:5060 (NAT)
Using INVITE request as basis request - 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
No matching peer for ‘10.0.0.5’ from ‘10.0.0.50:5060’

<— Reliably Transmitting (NAT) to 10.0.0.50:5060 —>
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK0abb81465a4dcc22bdbfe3fe99dcaf9a;received=10.0.0.50;rport=5060
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060;tag=as47c69b84
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956242 INVITE
Server: FPBX-13.0.192.8(13.14.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm=“asterisk”, nonce="4036d512"
Content-Length: 0

<------------>
Scheduling destruction of SIP dialog ‘6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50’ in 32000 ms (Method: INVITE)

<— SIP read from UDP:10.0.0.50:5060 —>
ACK sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK0abb81465a4dcc22bdbfe3fe99dcaf9a;rport
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060;tag=as47c69b84
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956242 ACK
Content-Length: 0

<------------->
— (7 headers 0 lines) —

<— SIP read from UDP:10.0.0.50:5060 —>
INVITE sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK6926e571176c0c581e829d42eb84cf68;rport
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956243 INVITE
Contact: sip:10.0.0.50
Authorization: Digest username="", realm=“asterisk”, nonce=“4036d512”, uri=“sip:444442@10.0.0.5:5060”, response=“da321d39fd3dad16ec39ae7f35a82ecf”, algorithm=MD5
Supported: replaces
User-Agent: siplib 3.0.25 Built on Feb 2 2013, 14:44:22
Allow: INVITE, ACK, CANCEL, BYE, OPTIONS, INFO, UPDATE, NOTIFY, REFER
Content-Type: application/sdp
Max-Forwards: 70
Content-Length: 291

v=0
o=Dinstar 2270656 2270657 IN IP4 10.0.0.50
s=-
c=IN IP4 10.0.0.50
t=0 0
m=audio 8028 RTP/AVP 18 0 8 4 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=yes
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:4 G723/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
a=ptime:20
<------------->
— (14 headers 14 lines) —
Sending to 10.0.0.50:5060 (NAT)
Using INVITE request as basis request - 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
No matching peer for ‘10.0.0.5’ from ‘10.0.0.50:5060’
[2017-06-07 16:59:38] NOTICE[4500][C-0000000d]: chan_sip.c:26179 handle_request_invite: Failed to authenticate device 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7

<— Reliably Transmitting (NAT) to 10.0.0.50:5060 —>
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK6926e571176c0c581e829d42eb84cf68;received=10.0.0.50;rport=5060
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060;tag=as47c69b84
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956243 INVITE
Server: FPBX-13.0.192.8(13.14.0)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0

<------------>
Scheduling destruction of SIP dialog ‘6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50’ in 32000 ms (Method: INVITE)

<— SIP read from UDP:10.0.0.50:5060 —>
ACK sip:444442@10.0.0.5:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.50;branch=z9hG4bK6926e571176c0c581e829d42eb84cf68;rport
From: 0907374005 sip:10.0.0.5:5060;tag=86675e9d0ecd0219ac174132a1e26ce7
To: sip:444442@10.0.0.5:5060;tag=as47c69b84
Call-ID: 6a4cabb77bb5c20c73177f1c89cfea32@10.0.0.50
CSeq: 67956243 ACK
Content-Length: 0

<------------->
— (7 headers 0 lines) —

<— SIP read from UDP:10.1.7.20:30990 —>

<------------->
Reliably Transmitting (no NAT) to 10.1.7.20:30990:
OPTIONS sip:1020@10.1.7.20:30990;rinstance=02575bba12a728b5 SIP/2.0
Via: SIP/2.0/UDP 10.0.0.5:5060;branch=z9hG4bK734fc744
Max-Forwards: 70
From: “Unknown” sip:Unknown@10.0.0.5;tag=as7d7c04e8
To: sip:1020@10.1.7.20:30990;rinstance=02575bba12a728b5
Contact: sip:Unknown@10.0.0.5:5060
Call-ID: 3d2d9a9511f6c4417da45255335d66e7@10.0.0.5:5060
CSeq: 102 OPTIONS
User-Agent: FPBX-13.0.192.8(13.14.0)
Date: Wed, 07 Jun 2017 09:59:49 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0


<— SIP read from UDP:10.1.7.20:30990 —>
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.0.5:5060;branch=z9hG4bK734fc744
Contact: sip:10.1.7.20:30990
To: sip:1020@10.1.7.20:30990;rinstance=02575bba12a728b5;tag=2261ce51
From: "Unknown"sip:Unknown@10.0.0.5;tag=as7d7c04e8
Call-ID: 3d2d9a9511f6c4417da45255335d66e7@10.0.0.5:5060
CSeq: 102 OPTIONS
Accept: application/sdp
Accept-Language: en
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
User-Agent: eyeBeam release 1102u stamp 52345
Content-Length: 0

------------------------------------ end of snap shot of sip --------------------------------------------------------
----------------------------------- chan_dahdi_groups.conf ------------------------------------------------------
cat /etc/asterisk/chan_dahdi_groups.conf
;--------------------------------------------------------------------------------;
; Do NOT edit this file as it is auto-generated by FreePBX. ;
;--------------------------------------------------------------------------------;
; For information on adding additional paramaters to this file, please visit the ;
; FreePBX.org wiki page, or ask on IRC. This file was created by the new FreePBX ;
; BMO - Big Module Object. Any similarity in naming with BMO from Adventure Time ;
; is totally deliberate. ;
;--------------------------------------------------------------------------------;

; [span_1]
signalling=pri_cpe
switchtype=euroisdn
pridialplan=dynamic
prilocaldialplan=dynamic
group=0
context=from-digital
channel=>1-15,17-31
priexclusive=yes

; [span_2]
signalling=pri_cpe
switchtype=euroisdn
pridialplan=dynamic
prilocaldialplan=dynamic
group=0
context=from-digital
channel=>32-46,48-62
priexclusive=yes

------------------------------ end of chan_dahdi_groups.conf----------------------------------------------
------------------------------- chan__dahdi.conf ---------------------------------------------------------------
;--------------------------------------------------------------------------------;
; Do NOT edit this file as it is auto-generated by FreePBX. ;
;--------------------------------------------------------------------------------;
; For information on adding additional paramaters to this file, please visit the ;
; FreePBX.org wiki page, or ask on IRC. This file was created by the new FreePBX ;
; BMO - Big Module Object. Any similarity in naming with BMO from Adventure Time ;
; is totally deliberate. ;
;--------------------------------------------------------------------------------;
[general]

; generated by module
#include chan_dahdi_general.conf

; for user additions not provided by module
#include chan_dahdi_general_custom.conf

[channels]
language=en
busydetect=yes
busycount=10
usecallerid=yes
callwaiting=yes
usecallingpres=yes
threewaycalling=yes
transfer=yes
cancallforward=yes
callreturn=yes
echocancel=yes
echocancelwhenbridged=no
echotraining=no
immediate=no
faxdetect=no
rxgain=0.0
txgain=0.0

; for user additions not provided by module
#include chan_dahdi_channels_custom.conf

; include dahdi groups defined by DAHDI module of FreePBX
#include chan_dahdi_groups.conf

; include dahdi extensions defined in FreePBX
#include chan_dahdi_additional.conf

------------------------------end of chan_dahdi.conf --------------------------------------------------------

Please re-paste your logs and configuration,but this time mark them as pre-formatted text!

Also, why did you only provide SIP debugging when your problem is not on a SIP channel?

Seems like he has a mix of issues and is throwing info randomly, the sip show a Forbidden response.

------------------------wanpipe1.conf in /etc/wanpipe/wanpipe1.conf-------------------------------

================================================
WANPIPE1 Configuration File

Date: Wed Dec 6 20:29:03 UTC 2006
Note: This file was generated automatically
by /usr/local/sbin/setup-sangoma program.
If you want to edit this file, it is
recommended that you use wancfg program
to do so.

Sangoma Technologies Inc.

[devices]
wanpipe1 = WAN_AFT_TE1, Comment

[interfaces]
w1g1 = wanpipe1, , TDM_VOICE, Comment

[wanpipe1]
CARD_TYPE = AFT
S514CPU = A
CommPort = PRI
AUTO_PCISLOT = NO
PCISLOT = 4
PCIBUS = 37
FE_MEDIA = E1
FE_LCODE = HDB3
FE_FRAME = NCRC4
FE_LINE = 1
TE_CLOCK = NORMAL
TE_REF_CLOCK = 0
TE_SIG_MODE = CCS
TE_HIGHIMPEDANCE = NO
TE_RX_SLEVEL = 430
HW_RJ45_PORT_MAP = DEFAULT
LBO = 120OH
FE_TXTRISTATE = NO
MTU = 1500
UDPPORT = 9000
TTL = 255
IGNORE_FRONT_END = NO
TDMV_SPAN = 1
TDMV_DCHAN = 16
TE_AIS_MAINTENANCE = NO #NO: defualt YES: Start port in AIS Blue Alarm and keep line down
#wanpipemon -i w1g1 -c Ttx_ais_off to disable AIS maintenance mode
#wanpipemon -i w1g1 -c Ttx_ais_on to enable AIS maintenance mode
TDMV_HW_DTMF = YES # YES: receive dtmf events from hardware
TDMV_HW_FAX_DETECT = NO # YES: receive fax 1100hz events from hardware
HWEC_OPERATION_MODE = OCT_NORMAL # OCT_NORMAL: echo cancelation enabled with nlp (default)

OCT_SPEECH: improves software tone detection by disabling NLP (echo possible)

OCT_NO_ECHO:disables echo cancelation but allows VQE/tone functions.

HWEC_DTMF_REMOVAL = NO # NO: default YES: remove dtmf out of incoming media (must have hwdtmf enabled)
HWEC_NOISE_REDUCTION = NO # NO: default YES: reduces noise on the line - could break fax
HWEC_ACUSTIC_ECHO = NO # NO: default YES: enables acustic echo cancelation
HWEC_NLP_DISABLE = NO # NO: default YES: guarantees software tone detection (possible echo)
HWEC_TX_AUTO_GAIN = 0 # 0: disable -40-0: default tx audio level to be maintained (-20 default)
HWEC_RX_AUTO_GAIN = 0 # 0: disable -40-0: default tx audio level to be maintained (-20 default)
HWEC_TX_GAIN = 0 # 0: disable -24-24: db values to be applied to tx signal
HWEC_RX_GAIN = 0 # 0: disable -24-24: db values to be applied to tx signal

[w1g1]
ACTIVE_CH = ALL
TDMV_HWEC = YES
MTU = 8
----------------------------End of file wanpipe1.conf----------------------------------------------------------
---------------------------- snap shot of asterisk console -----------------------------------------------------
– Registered SIP ‘1020’ at 10.1.7.20:36156
[2017-06-08 15:09:21] NOTICE[4500]: chan_sip.c:24457 handle_response_peerpoke: Peer ‘1020’ is now Reachable. (21ms / 2000ms)
[2017-06-08 15:09:21] NOTICE[4500]: chan_sip.c:28276 handle_request_subscribe: Received SIP subscribe for peer without mailbox: 1020
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Executing [0909303986@from-pstn:1] Set(“SIP/1020-00000002”, “__FROM_DID=0909303986”) in new stack
– Executing [0909303986@from-pstn:2] NoOp(“SIP/1020-00000002”, “Received an unknown call with DID set to 0909303986”) in new stack
– Executing [0909303986@from-pstn:3] Goto(“SIP/1020-00000002”, “s,a2”) in new stack
– Goto (from-pstn,s,2)
– Executing [s@from-pstn:2] Answer(“SIP/1020-00000002”, “”) in new stack
– Executing [s@from-pstn:3] Log(“SIP/1020-00000002”, “WARNING,Friendly Scanner from 10.1.7.20”) in new stack
[2017-06-08 15:09:24] WARNING[2507][C-00000065]: Ext. s:3 @ from-pstn: Friendly Scanner from 10.1.7.20
– Executing [s@from-pstn:4] Wait(“SIP/1020-00000002”, “2”) in new stack
– Executing [s@from-pstn:5] Playback(“SIP/1020-00000002”, “ss-noservice”) in new stack
– <SIP/1020-00000002> Playing ‘ss-noservice.ulaw’ (language ‘en’)
– Executing [s@from-pstn:6] SayAlpha(“SIP/1020-00000002”, “0909303986”) in new stack
– <SIP/1020-00000002> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/3.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/3.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/8.ulaw’ (language ‘en’)
– <SIP/1020-00000002> Playing ‘digits/6.ulaw’ (language ‘en’)
– Executing [s@from-pstn:7] Hangup(“SIP/1020-00000002”, “”) in new stack
== Spawn extension (from-pstn, s, 7) exited non-zero on ‘SIP/1020-00000002’
– Executing [h@from-pstn:1] Macro(“SIP/1020-00000002”, “hangupcall,”) in new stack
– Executing [s@macro-hangupcall:1] GotoIf(“SIP/1020-00000002”, “1?theend”) in new stack
– Goto (macro-hangupcall,s,3)
– Executing [s@macro-hangupcall:3] ExecIf(“SIP/1020-00000002”, “0?Set(CDR(recordingfile)=)”) in new stack
– Executing [s@macro-hangupcall:4] Hangup(“SIP/1020-00000002”, “”) in new stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘SIP/1020-00000002’ in macro ‘hangupcall’
== Spawn extension (from-pstn, h, 1) exited non-zero on ‘SIP/1020-00000002’
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Executing [0909303986@from-pstn:1] Set(“SIP/1020-00000003”, “__FROM_DID=0909303986”) in new stack
– Executing [0909303986@from-pstn:2] NoOp(“SIP/1020-00000003”, “Received an unknown call with DID set to 0909303986”) in new stack
– Executing [0909303986@from-pstn:3] Goto(“SIP/1020-00000003”, “s,a2”) in new stack
– Goto (from-pstn,s,2)
– Executing [s@from-pstn:2] Answer(“SIP/1020-00000003”, “”) in new stack
– Executing [s@from-pstn:3] Log(“SIP/1020-00000003”, “WARNING,Friendly Scanner from 10.1.7.20”) in new stack
[2017-06-08 15:09:46] WARNING[2509][C-00000066]: Ext. s:3 @ from-pstn: Friendly Scanner from 10.1.7.20
– Executing [s@from-pstn:4] Wait(“SIP/1020-00000003”, “2”) in new stack
– Executing [s@from-pstn:5] Playback(“SIP/1020-00000003”, “ss-noservice”) in new stack
– <SIP/1020-00000003> Playing ‘ss-noservice.ulaw’ (language ‘en’)
– Executing [s@from-pstn:6] SayAlpha(“SIP/1020-00000003”, “0909303986”) in new stack
– <SIP/1020-00000003> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/3.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/0.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/3.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/9.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/8.ulaw’ (language ‘en’)
– <SIP/1020-00000003> Playing ‘digits/6.ulaw’ (language ‘en’)
– Executing [s@from-pstn:7] Hangup(“SIP/1020-00000003”, “”) in new stack
== Spawn extension (from-pstn, s, 7) exited non-zero on ‘SIP/1020-00000003’
– Executing [h@from-pstn:1] Macro(“SIP/1020-00000003”, “hangupcall,”) in new stack
– Executing [s@macro-hangupcall:1] GotoIf(“SIP/1020-00000003”, “1?theend”) in new stack
– Goto (macro-hangupcall,s,3)
– Executing [s@macro-hangupcall:3] ExecIf(“SIP/1020-00000003”, “0?Set(CDR(recordingfile)=)”) in new stack
– Executing [s@macro-hangupcall:4] Hangup(“SIP/1020-00000003”, “”) in new stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘SIP/1020-00000003’ in macro ‘hangupcall’
== Spawn extension (from-pstn, h, 1) exited non-zero on ‘SIP/1020-00000003’
[2017-06-08 15:10:22] NOTICE[4500]: chan_sip.c:28276 handle_request_subscribe: Received SIP subscribe for peer without mailbox: 1020

------------------------------------ end of snap shot of sip --------------------------------------------------------
----------------------------------- chan_dahdi_groups.conf ------------------------------------------------------
cat /etc/asterisk/chan_dahdi_groups.conf
;--------------------------------------------------------------------------------;
; Do NOT edit this file as it is auto-generated by FreePBX. ;
;--------------------------------------------------------------------------------;
; For information on adding additional paramaters to this file, please visit the ;
; FreePBX.org wiki page, or ask on IRC. This file was created by the new FreePBX ;
; BMO - Big Module Object. Any similarity in naming with BMO from Adventure Time ;
; is totally deliberate. ;
;--------------------------------------------------------------------------------;

; [span_1]
signalling=pri_cpe
switchtype=euroisdn
pridialplan=dynamic
prilocaldialplan=dynamic
group=0
context=from-digital
channel=>1-15,17-31
priexclusive=yes

; [span_2]
signalling=pri_cpe
switchtype=euroisdn
pridialplan=dynamic
prilocaldialplan=dynamic
group=0
context=from-digital
channel=>32-46,48-62
priexclusive=yes

------------------------------ end of chan_dahdi_groups.conf----------------------------------------------
------------------------------- chan__dahdi.conf ---------------------------------------------------------------
;--------------------------------------------------------------------------------;
; Do NOT edit this file as it is auto-generated by FreePBX. ;
;--------------------------------------------------------------------------------;
; For information on adding additional paramaters to this file, please visit the ;
; FreePBX.org wiki page, or ask on IRC. This file was created by the new FreePBX ;
; BMO - Big Module Object. Any similarity in naming with BMO from Adventure Time ;
; is totally deliberate. ;
;--------------------------------------------------------------------------------;
[general]

; generated by module

#include chan_dahdi_general.conf
; for user additions not provided by module

#include chan_dahdi_general_custom.conf
[channels]
language=en
busydetect=yes
busycount=10
usecallerid=yes
callwaiting=yes
usecallingpres=yes
threewaycalling=yes
transfer=yes
cancallforward=yes
callreturn=yes
echocancel=yes
echocancelwhenbridged=no
echotraining=no
immediate=no
faxdetect=no
rxgain=0.0
txgain=0.0

; for user additions not provided by module

#include chan_dahdi_channels_custom.conf
; include dahdi groups defined by DAHDI module of FreePBX

#include chan_dahdi_groups.conf
; include dahdi extensions defined in FreePBX

#include chan_dahdi_additional.conf

If you see lots of very large text, you have not marked the text as pre-formatted and important information may be missing.

Please share a sample me what is the meaning of pre-formatted text

You need to use the icon “<\ />” (without the first \ ) in the editor to enable preformatted text.

You are using FreePBX right? Seems like your inbound route is not properly set, if you are using freepbx do not edit files and ask in their forums.