[SOLVED] Problem to make a call to the PSTN

I have an AP200D (Addpac) of 2 FXO, which I want to use to call outgoing and ingoing calls (Local Area Network [with Asterisk] <-> PSTN)

Now, I can make a call from PSTN to the client of asterisk: 80, but I can’t make a call from an extension of Asterisk to the PSTN

These are the configuration files:

sip.conf:

[general]
port=5060
disallow=all
;allow=g729
allow=ulaw
;allow=alaw
;

[82]
; AP200D
type=friend
host=dynamic
context=internal
language=es
secret=82
username=82
callerid=82
dtmfmode=rfc2833
qualify=yes
nat=no
insecure=very
canreinvite=no

extensions.conf

; Calls to PSTN:
exten => _XXXXXXX,1,Dial(SIP/82/${EXTEN})
exten => _XXXXXXX,2,Hangup

; Calls from PSTN
exten => 11,1,Goto(ivr,s,1)
; Here goes an IVR …

When I want to call to the PSTN, the handset sounds like there were NO extension for that number (2636483).

Name/username Host Dyn Nat ACL Port Status
82/82 192.168.3.15 D 5060 OK (43 ms)
– Saved useragent “AddPac SIP Gateway” for peer 82

In Asterisk it shows me:

-- Executing [2636484@internal:1] Dial("SIP/80-081d71f8", "SIP/82/2636483") in new stack
-- Called 82/2636484
-- SIP/82-081dc1a8 is circuit-busy

== Everyone is busy/congested at this time (1:0/1/0)
– Executing [2636484@internal:2] Hangup(“SIP/80-081d71f8”, “”) in new stack
== Spawn extension (internal, 2636484, 2) exited non-zero on ‘SIP/80-081d71f8’

When I make a debug in the AP200D, it shows me this:

Received SIP PDU from < 192.168.3.49:5060 >
INVITE sip:2636484@192.168.3.15 SIP/2.0
Via: SIP/2.0/UDP 192.168.3.49:5060
From: “80” sip.80@192.168.3.49
To: sip:2636483@192.168.3.15
Contact: sip:80@192.168.3.49

Sending SIP PDU to < 192.168.3.49:5060 > from 5060
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.3.49:5060
From: “80” sip.80@192.168.3.49
To: sip:2636484@192.168.3.15

Sending SIP PDU to < 192.168.3.49:5060 > from 5060
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 192.168.3.49:5060
From: “80” sip.80@192.168.3.49
To: sip:2636484@192.168.3.15

I think I have to change something in the configuration files from Asterisk. What I should do?

Thanks in advanced.

Pedro

I dave had exactly the same problem and solved it today.
See http://forums.digium.com/viewtopic.php?t=66371
It was a matter of wrongly set section. Maybe it’s worth to compare your config with mine ?

Hello idefix, thanks for the answer

I made some changes after reading your answer, but it didn’t work yet.

Sip.conf:

[general]
;
port=5060
disallow=all
allow=ulaw

[82]
type=friend
;port=5061
host=dynamic
context=internal
language=es
secret=82
username=82
callerid=82
dtmfmode=rfc2833
qualify=yes
nat=not
insecure=port,invite
canreinvite=no

Extensions.conf:

; Call to PSTN:
exten => _X.,1,Dial(SIP/${EXTEN}@82,30,trg)
exten => _X.,2,Hangup

When I make a call from extension 80 to number from the PSTN: 2636483, I still hear a sound like I were making a call to an invalid extension in sip.conf :S

-- Executing [2636483@internal:1] Dial("SIP/80-081d6ef0", "SIP/2636483@82|30|trg") in new stack
-- Called 2636483@82
-- SIP/82-081dc158 is circuit-busy

== Everyone is busy/congested at this time (1:0/1/0)
– Executing [2636483@internal:2] Hangup(“SIP/80-081d6ef0”, “”) in new stack
== Spawn extension (internal, 2636483, 2) exited non-zero on ‘SIP/80-081d6ef0’
– Saved useragent “AddPac SIP Gateway” for peer 82

Please, what other ideas do you have?
Thanks,
Pedro

This link help to solve my problem :smile:

voip-info.org/wiki-Asterisk+cisco+FXO

In my case It was almost the same configuration from the voip-web that I have to add and also to change some wrong lines.

If someone needs help with this topic about Asterisk and Addpac AP200D feel free to email me:

p.valera@pucp.edu.pe

Pedro