guys, i am a newbie on asterisk develop. i get trouble about my asterisk, if From PSTN Line to call my PBX and then press an extension but that extension is busy i want this to forward ivr busy but this is not . My ip phone is Fanvil C56. Please help and suggestion. Thanks…
[custom-default]
;Recording Voice
exten => 5678,1,Ringing
exten => 5678,2,Wait(2)
exten => 5678,3,Playback(press-pound-save-changes)
exten => 5678,4,Record(/tmp/rekaman-anwar:gsm)
exten => 5678,5,Wait(1)
exten => 5678,6,Playback(/tmp/rekaman-anwar)
exten => 5678,7,Wait(2)
exten => 5678,8,Hangup
;listen Moh
exten => 5656,1,Answer()
exten => 5656,2,MusicOnHold()
exten => 5656,3,Hangup()
[jadwal]
; GotoIfTime(time|dayofweek|month|year?destination)
; Jika waktu jam 7.30-17, senin-jumat lempar ke ivr
; Diluar dari jadwal yang diatas lempar ke security
; Contoh libur tanggal 25 Desember 2012, maka dialplannya menjadi:
; exten => 5757,1,GotoIfTime(,,25,dec?security,1001,1)
; exten => 5757,2,GotoIfTime(7:30-13:00,sat,,?ivr,100,1)
; exten => 5757,3,GotoIfTime(7:30-16:30,mon-fri,,?ivr,100,1)
; exten => 5757,4,GotoIfTime(,,,?security,1001,1)
exten => 5757,1,GotoIfTime(7:30-12:00,sat,,?ivr,100,1)
exten => 5757,2,GotoIfTime(7:30-16:30,mon-fri,,?ivr,100,1)
exten => 5757,3,GotoIfTime(,,,?security,1001,1)
[to-pstn]
include => from-internal
; Semua telpon minimum 6 digit dengan:
; X: 0-9; Z: 1-9; N: 2-9; [12679] - any digit in the brakets (in the example: 1,2,6,7,9); . (dot) wildcard, matches everything remaining
; password untuk menelpon keluar dari operator adalah 7890
exten => _XXXXX.,1,Playback(vm-password)
exten => _XXXXX.,2,Authenticate(7890)
exten => _XXXXX.,3,Dial(SIP/${EXTEN}@4108)
;exten => _XXXXX.,4,Goto(${DIALSTATUS})
;exten => _XXXXX.,5(NOANSWER),Playback(vm-nobodyavail)
;exten => _XXXXX.,6,Playback(vm-pls-try-again)
;exten => _XXXXX.,7,Hangup
;exten => _XXXXX.,8(BUSY),Playback(all-circuits-busy-now)
;exten => _XXXXX.,9,Playback(vm-pls-try-again)
;exten => _XXXXX.,10,Hangup
;exten => _XXXXX.,11(CHANUNAVAIL),Playback(all-outgoing-lines-unavailable)
;exten => _XXXXX.,12,Playback(vm-pls-try-again)
;exten => _XXXXX.,13,Hangup
;exten => _XXXXX.,14(CONGESTION),Playback(all-outgoing-lines-unavailable)
;exten => _XXXXX.,15,Playback(vm-pls-try-again)
exten => _XXXXX.,4,Hangup
[security]
exten => 1001,1,Dial(SIP/1001,20,t)
exten => 1001,2,Goto(${DIALSTATUS})
exten => 1001,3(NOANSWER),Playback(vm-nobodyavail)
exten => 1001,4,Playback(vm-pls-try-again)
exten => 1001,5,Hangup
exten => 1001,6(BUSY),Playback(vm-nobodyavail)
exten => 1001,7,Playback(vm-pls-try-again)
exten => 1001,8,Hangup
exten => 1001,9(CHANUNAVAIL),Playback(vm-nobodyavail)
exten => 1001,10,Playback(vm-pls-try-again)
exten => 1001,11,Hangup
[ivr]
exten => 100,1,Set(CALLERID(name)=FROM-PSTN)
exten => 100,n,Answer
exten => 100,n,Background(welcome-indofero)
exten => 100,n,WaitExten(5)
; Jika dalam 5 detik tidak menekan extensi maka akan dilempar ke operator
exten => 100,n,Goto(from-internal,0,1)
exten => 100,n,Hangup
; Jika menekan extensi direksi maka akan dioper ke operator
exten => 1111,1,Goto(from-internal,0,1)
exten => 1188,1,Goto(from-internal,0,1)
exten => 1222,1,Goto(from-internal,0,1)
include => from-internal
[busy-tone]
exten => s,1,Background(busy-tone)
exten => s,n,WaitExten(5)
exten => s,n,Goto(from-internal,0,1)
exten => s,n,Hangup
include => from-internal
[from-internal]
include => ivr
include => custom-default
;Call From Internal
;Press 0 For Operator
exten => 0,1,Dial(SIP/1000,20,t)
exten => 0,2,Goto(${DIALSTATUS})
exten => 0,3(NOANSWER),Playback(vm-nobodyavail)
exten => 0,4,Playback(vm-pls-try-again)
exten => 0,5,Hangup
exten => 0,6(BUSY),Goto(busy-tone,s,1)
exten => 0,7,Hangup
exten => 0,8(CHANUNAVAIL),Goto(busy-tone,s,1)
exten => 0,9,Hangup
exten => _1XXX,1,Dial(SIP/${EXTEN},20,t)
exten => _1XXX,2,Goto(${DIALSTATUS})
exten => _1XXX,3(NOANSWER),Playback(followme/status)
exten => _1XXX,4,Goto(from-internal,0,1)
exten => _1XXX,5,Hangup
exten => _1XXX,6(BUSY),Goto(busy-tone,s,1)
exten => _1XXX,7,Hangup
exten => _1XXX,8(CHANUNAVAIL),Goto(busy-tone,s,1)
exten => _1XXX,9,Hangup
exten => _1XXX,10(CONGESTION),Goto(busy-tone,s,1)
exten => _1XXX,11,Hangup
exten => _2XXX,1,Dial(SIP/${EXTEN},20,t)
exten => _2XXX,2,Goto(${DIALSTATUS})
exten => _2XXX,3(NOANSWER),Playback(followme/status)
exten => _2XXX,4,Goto(from-internal,0,1)
exten => _2XXX,5,Hangup
exten => _2XXX,6(BUSY),Goto(busy-tone,s,1)
exten => _2XXX,7,Hangup
exten => _2XXX,8(CHANUNAVAIL),Goto(busy-tone,s,1)
exten => _2XXX,9,Hangup
exten => _2XXX,10(CONGESTION),Goto(busy-tone,s,1)
exten => _2XXX,11,Hangup
exten => _3XXX,1,Dial(SIP/${EXTEN},20,t)
exten => _3XXX,2,Goto(${DIALSTATUS})
exten => _3XXX,3(NOANSWER),Playback(followme/status)
exten => _3XXX,4,Goto(from-internal,0,1)
exten => _3XXX,5,Hangup
exten => _3XXX,6(BUSY),Goto(busy-tone,s,1)
exten => _3XXX,7,Hangup
exten => _3XXX,8(CHANUNAVAIL),Goto(busy-tone,s,1)
exten => _3XXX,9,Hangup
exten => _3XXX,10(CONGESTION),Goto(busy-tone,s,1)
exten => _3XXX,11,Hangup