I'm trying to get Asterisk to dail outboud using the SPA-3000 and the plain old telephone line attached to it. My configs below are cobbled together from various posts including this site. I am able to receive calls and have routed pstn to a sip phone I have connected on my desk. Just need to get it work the other way. Thanks in advance for looking this over.
output from sip show peers:
4 sip peers [Monitored: 0 online, 0 offline Unmonitored: 3 online, 1 offline]
The error I'm getting in the CLI:
Connected to Asterisk 17.7.0 currently running on pbx01 (pid = 3782)
== Using SIP RTP CoS mark 5
> 0x7f6c00007740 -- Strict RTP learning after remote address set to: 192.168.7.40:16626
-- Executing [96665555@local-phone:1] Goto("SIP/700-00000000", "outgoing,6576757") in new stack
-- Goto (local-phone,outgoing,6665555)
[Sep 17 15:26:42] WARNING[3842][C-00000001]: pbx.c:4510 __ast_pbx_run: Channel 'SIP/700-00000000' sent to invalid extension but no invalid handler: context,exten,priority=local-phone,outgoing,6665555
My sip.conf
[general]
tcpenable=yes
transport=udp
context=local-phone
[demo-bob]
type=friend
secret=somepwd2; put a strong, unique password here instead
[700]
type=friend
host=dynamic
secret=pass
disallow=all
allow=ulaw
[spa3000]
mailbox=3000 ; Mailbox number (numerical so can be selected through phone)
type=friend
canreinvite=yes
nat=no
host=dynamic
secret=someotherpwd
call-limit=2
disallow=all
allow=ulaw
allow=g729
allow=gsm
[ptsn]
type=friend
canreinvite=yes
host=dynamic
secret=somepwd
call-limit=2
nat=no
port=5061
disallow=all
allow=ulaw
;allow=g723.1
allow=g729
allow=gsm
My extensions.conf
[local-phone]
exten = 2002,1,Answer()
same = n,Wait(1)
same = n,Playback(hello-world)
same = n,Hangup()
exten => 115,2,Dial(SIP/115) ; see “show application dial” for options and formats
exten => 115,4,Voicemail2(u115) ; go to Voicemail2 if phone is “U”nanswered
exten => 115,102,Voicemail2(b115) ; go to Voicemail2 if phone is “B”usy
exten => 115,103,Hangup ; and then hangup.
exten => 700,1, Dial(SIP/700,10,t)
exten => 700,4,Voicemail2(u700) ; go to Voicemail2 if phone is “U”nanswered
exten => 700,102,Voicemail2(b700) ; go to Voicemail2 if phone is “B”usy
exten => 700,103,Hangup ; and then hangup.
exten => _9X.,1,Goto(outgoing,${EXTEN:1})
[incoming]
exten => ptsn,1,Goto(local-phone,700,1)
[outgoing]
exten => _X.,1,Dial(SIP/ptsn,20)
output from sip show peers:
| Name/username | Host | Dyn | Forcerport | Comedia | ACL | Port | Status | Description |
| 700/700 | 192.168.7.40 | D | Auto (No) | No | 5060 | Unmonitored | ||
| demo-bob | (Unspecified) | Auto (No) | No | 0 | Unmonitored | |||
| ptsn/ptsn | 192.168.7.61 | D | No | No | 5061 | Unmonitored | ||
| spa3000/spa3000 | 192.168.7.61 | D | No | No | 5060 | Unmonitored |
The error I'm getting in the CLI:
Connected to Asterisk 17.7.0 currently running on pbx01 (pid = 3782)
== Using SIP RTP CoS mark 5
> 0x7f6c00007740 -- Strict RTP learning after remote address set to: 192.168.7.40:16626
-- Executing [96665555@local-phone:1] Goto("SIP/700-00000000", "outgoing,6576757") in new stack
-- Goto (local-phone,outgoing,6665555)
[Sep 17 15:26:42] WARNING[3842][C-00000001]: pbx.c:4510 __ast_pbx_run: Channel 'SIP/700-00000000' sent to invalid extension but no invalid handler: context,exten,priority=local-phone,outgoing,6665555
My sip.conf
[general]
tcpenable=yes
transport=udp
context=local-phone
[demo-bob]
type=friend
secret=somepwd2; put a strong, unique password here instead
[700]
type=friend
host=dynamic
secret=pass
disallow=all
allow=ulaw
[spa3000]
mailbox=3000 ; Mailbox number (numerical so can be selected through phone)
type=friend
canreinvite=yes
nat=no
host=dynamic
secret=someotherpwd
call-limit=2
disallow=all
allow=ulaw
allow=g729
allow=gsm
[ptsn]
type=friend
canreinvite=yes
host=dynamic
secret=somepwd
call-limit=2
nat=no
port=5061
disallow=all
allow=ulaw
;allow=g723.1
allow=g729
allow=gsm
My extensions.conf
[local-phone]
exten = 2002,1,Answer()
same = n,Wait(1)
same = n,Playback(hello-world)
same = n,Hangup()
exten => 115,2,Dial(SIP/115) ; see “show application dial” for options and formats
exten => 115,4,Voicemail2(u115) ; go to Voicemail2 if phone is “U”nanswered
exten => 115,102,Voicemail2(b115) ; go to Voicemail2 if phone is “B”usy
exten => 115,103,Hangup ; and then hangup.
exten => 700,1, Dial(SIP/700,10,t)
exten => 700,4,Voicemail2(u700) ; go to Voicemail2 if phone is “U”nanswered
exten => 700,102,Voicemail2(b700) ; go to Voicemail2 if phone is “B”usy
exten => 700,103,Hangup ; and then hangup.
exten => _9X.,1,Goto(outgoing,${EXTEN:1})
[incoming]
exten => ptsn,1,Goto(local-phone,700,1)
[outgoing]
exten => _X.,1,Dial(SIP/ptsn,20)