[Asterisk-Users] Totally LOST with dialplan and Extensions.
David Uzzell
asterisk-list at uzzell.com.au
Sun Dec 12 08:39:21 MST 2004
Ok I have spent the last week working on getting my small PBX to work.
I will in the end only have 4 SIP extensions being either softphones of
IP phones. Currently only 1 SIP config for testing.
And at the this point it should be all fairly easy with all inbound and
outbound to PSTN will be going Via Firefly/Freshtel.net in Australia via
IAX. Inbound does work in it's current basic state.
There will be NO ZAP devices, so I have ztdummy running.
I would say that for the outbound dialing I have either missed out
something plainly obvious or a simple typo which would be the challange.
I would think that all the problems are in the extensions.conf file
which really has me confused and totally lost.
I don't expect answers just pointers in the correct direction so that I
can get it to work for the outbound calling to work, I have the inbound
working which was a task but I was able with some pointers to get it
working.
I would like to thank you all for your casting experianced eyes to look
over this. What ever is worked out I will make sure the info gets onto
the Wiki for Freshtel and for a SIP to IAX to PSTN config so that others
can look up the basic configs to do this type of setup. There does not
seem to be from what I can find this basic configs for IAX without FXS &
FXO devices.
cheers
David
SIP.CONF
[general]
context=default
realm=monitor.diversified.com.au
bindaddr=203.29.98.221
srvlookup=yes
maxexpirey=180
defaultexpirey=160
disallow=all
allow=speex
allow=gsm
allow=ilbc
allow=ulaw
allow=ilbc
[801]
type=friend
regexten=801
username=801
secret=password
callerid=801
host=dynamic
nat=yes
canreinvite=no
qualify=yes
disallow=all
allow=gsm
allow=speex
allow=ulaw
allow=alaw
IAX.CONF
[general]
tos=lowdelay
jitterbuffer=no
disallow=all
allow=speex
allow=ilbc
allow=gsm
allow=adpcm
allow=alaw
register => 89280250:password at cts-au.freshtel.net
register => 89280250:password at gateway.freshtel.net
[guest]
type=user
context=default
auth=none
;inbound
[firefly]
type=friend
host=cts-au.freshtel.net
context=default
; outbound
; Firefly (Freshtel)
[89280250] ; Firefly
context=89280250
qualify=no
username=89280250
secret=password
auth=md5
type=friend
host=gateway.freshtel.net
EXTENSIONS.CONF
[general]
static=yes
writeprotect=no
[globals]
SpeakingClock=123
[default]
exten => s,1,Wait,1
exten => s,n,Answer
exten => s,n,DigitTimeout,5
exten => s,n,ResponseTimeout,10
exten => s,n,WaitExten
exten => s,n,Dial(SIP/801)
exten => 13,1,DateTime()
exten => 13,2,Wait(1)
exten => 13,3,DateTime()
exten => 13,4,Hangup
exten => t,1,Goto(#,1)
exten => i,1,Playback(invalid)
exten => 600,1,Playback(demo-echotest)
exten => 600,n,Echo
exten => 600,n,Playback(demo-echodone)
exten => 600,n,Goto(s,6)
exten => ${SpeakingClock},1,Wait(1)
exten => ${SpeakingClock},2,setvar(FutureTime=$[${EPOCH} + 10])
exten => ${SpeakingClock},3,Wait,3
exten => ${SpeakingClock},4,SayUnixTime(${FutureTime},,R)
exten => ${SpeakingClock},5,playback(vm-and)
exten => ${SpeakingClock},6,SayUnixTime(${FutureTime},,S)
exten => ${SpeakingClock},7,playback(seconds)
exten => ${SpeakingClock},8,playback(beep)
exten => ${SpeakingClock},9,wait(2)
exten => ${SpeakingClock},10,goto(1)
exten => _394.,1,SetCallderId(89280250)
exten =>
_394.,2,Dial(IAX2/89280250:password at cts-au.freshtel.net/${EXTEN:3},60,r)
[outgoing-firefly-peers]
exten => _62XXXXXXXX,1,Macro(outgoingfirefly,${EXTEN:2},70) ; Firefly
[macro-outgoingfirefly]
exten => s,1,SetCallerID("89280250" <89280250>)
exten =>
s,2,Dial(IAX2/89280250:password at gateway.freshtel.net/${ARG1},${ARG2},r)
exten => s,3,Congestion
[macro-outgoingfreshtel]
exten => s,1,SetCallerID("89280250" <89280250>)
exten =>
s,2,Dial(IAX2/89280250:password at cts-au.freshtel.net/${ARG1},${ARG2},r)
exten => s,3,Congestion
More information about the asterisk-users
mailing list