hello
anyone know how to hangup call from/to pstn phone.
this is the scenario…
- The pstn phone call the asterisk server and directed to zap phone or sip phone extensions. after the conversation the pstn phone has been hangup prior to zap/sip phone. since zap/sip is not yet hangup i noticed that the channel still established connection though the pstn phone has been hangup.
Likewise, when i call pstn phone from zap/sip phone and after conversation
where pstn phone has been hanggup first the zap/sip channel stiil established
connection.
why is this happening?
here is my extensions.conf
[general]
static=yes
writeprotect=no
autofallthrough=yes
clearglobalvars=no
priorityjumping=no
[globals]
[globals]
CONSOLE=Console/dsp ; Console interface for demo
TRUNK=Zap/g1 ;PSTN = Channel 1-8
RECEPTIONIST=Zap/9 ;Receptionist = Channel 9
PHONE_10=Zap/10
PHONE_11=Zap/11
PHONE_12=Zap/12
PHONE_13=Zap/13
PHONE_14=Zap/14
PHONE_15=Zap/15
PHONE_16=Zap/16
PHONE_17=Zap/17
PHONE_18=Zap/18
PHONE_19=Zap/19
PHONE_20=Zap/20
PHONE_21=Zap/21
PHONE_22=Zap/22
PHONE_23=Zap/23
PHONE_24=Zap/24
SIP_1=SIP/kerberos
SIP_2=SIP/anton
[incoming]
include => internal
exten => s,1,Wait(3)
exten => s,2,Answer()
exten => s,3,Background(silence/1)
exten => s,4,BackgroundDetect(enter-ext-of-person)
exten => 1,1,Goto(internal,271,1)
exten => 1,2,Goto(incoming,s,1)
exten => 2,1,Goto(internal,251,1)
exten => 2,2,Goto(incoming,s,1)
exten => 3,1,Goto(internal,231,1)
exten => 3,2,Goto(incoming,s,1)
exten => 4,1,Goto(internal,302,1)
exten => 4,2,Goto(incoming,s,1)
exten => 5,1,Goto(internal,331,1)
exten => 5,2,Goto(incoming,s,1)
exten => 6,1,Goto(internal,351,1)
exten => 6,2,Goto(incoming,s,1)
exten => 7,1,Goto(internal,921,1)
exten => 7,2,Goto(incoming,s,1)
exten => 8,1,Goto(internal,941,1)
exten => 8,2,Goto(incoming,s,1)
exten => 0,1,Goto(internal,0,1)
exten => 0,2,Goto(incoming,s,1)
exten => i,1,Playback(pbx-invalid)
exten => i,2,Goto(incoming,s,1)
exten => t,1,Playback(vm-goodbye)
exten => t,2,Hangup()
[internal]
include => macro-voicemail
ignorepat => 9
exten => 0,1,Macro(voicemail,${RECEPTIONIST})
exten => 201,1,Macro(voicemail,${PHONE_10})
exten => 202,1,Macro(voicemail,${PHONE_11})
exten => 203,1,Macro(voicemail,${PHONE_12})
exten => 231,1,Macro(voicemail,${PHONE_13})
exten => 251,1,Macro(voicemail,${PHONE_14})
exten => 271,1,Macro(voicemail,${PHONE_15})
exten => 301,1,Macro(voicemail,${PHONE_16})
exten => 302,1,Macro(voicemail,${PHONE_17})
exten => 331,1,Macro(voicemail,${PHONE_18})
exten => 333,1,Macro(voicemail,${PHONE_19})
exten => 351,1,Macro(voicemail,${PHONE_20})
exten => 921,1,Macro(voicemail,${PHONE_21})
exten => 941,1,Macro(voicemail,${PHONE_22})
exten => 801,1,Answer()
exten => 801,2,Dial(${PHONE_23},30)
exten => 801,3,Playback(vm-nobodyavail)
exten => 801,4,Hangup()
exten => 123,1,Answer()
exten => 123,2,Dial(${PHONE_24},30)
exten => 123,3,Playback(vm-nobodyavail)
exten => 123,4,Hangup()
exten => 334,1,Macro(voicemail,${SIP_1})
exten => 321,1,Macro(voicemail,${SIP_2})
exten => 888,1,Answer()
exten => 888,2,VoiceMailMain(@our_voicemail)
exten => 888,3,Hangup()
exten => 8000,1,Goto(conf,1)
exten => conf,1,Set(MEETME_RECORDINGFILE=/tmp/Tutorial-$ {TIMESTAMP})
exten => conf,2,Meetme(8000|sr)
exten => conf,3,Hangup()
exten => 1337,1,Goto(count,1)
exten => count,1,MeetMecount(1234|USERS)
exten => count,2,NoOp(Total: ${USERS} users)
exten => 555,1,Directory(our_voicemail,internal,f)
exten => 444,1,Directory(our_voicemail,internal)
exten => _9NXXXXXX,1,Dial(${TRUNK}/${EXTEN:1})
[macro-voicemail]
exten => s,1,Dial(${ARG1},20)
exten => s,2,Goto(s-${DIALSTATUS},1)
exten => s-NOANSWER,1,Voicemail(u${MACRO_EXTEN}@our_voicemail)
exten => s-NOANSWER,2,Goto(incoming,s,1)
exten => s-BUSY,1,Voicemail(b${MACRO_EXTEN}@our_voicemail)
exten => s-BUSY,2,Goto(incoming,s,1)
exten => _s-.,1,Goto(s-NOANSWER,1)
here is my zapata.conf
[channels]
group => 1
language=en
usecallerid=yes
hidecallerid=no
callwaiting=no
threewaycalling=yes
transfer=yes
echocancel=yes
echocancelwhenbridged=yes
echotraining=yes
rxgain=8.2
txgain=1.0
context => incoming
signalling => fxs_ks
amaflags => documentation
channel => 1-8
group => 2
usecallerid=yes
hidecallerid=no
callwaiting=no
threewaycalling=yes
transfer=yes
echocancel=yes
echocancelwhenbridged=yes
echotraining=yes
rxgain=8.2
txgain=1.0
immediate=no
context => internal
signalling => fxo_ls
mailbox => 0000
callerid => “Receptionist”<number e.g 2314141>
channel => 9
mailbox => 201
callerid => “Bill” <number 201>
channel => 10
mailbox => 202
callerid => “Handel” <number 202>
channel => 11
mailbox => 203
callerid => “Gifford” <number 203>
channel => 12
mailbox => 231
callerid => “Bobot” <number 204>
channel => 13
mailbox => 251
callerid => “Fedila” <number 205>
channel => 14
mailbox => 271
callerid => "Fritz <number 206>"
channel => 15
mailbox => 301
callerid => “Ayek” <number 301>
channel => 16
mailbox => 302
callerid => “Karen” <number 302>
channel => 17
mailbox => 331
callerid => “Henry” <number 304>
channel => 18
mailbox => 333
callerid => “Kerberos” <number 305>
channel => 19
mailbox => 351
callerid => “Cris” <number 303>
channel => 20
mailbox => 801
callerid => “GYM” <number 801>
channel => 21
mailbox => 100
callerid => “Guardhouse” <number 100>
channel => 22
here is my zaptel.conf
pan=1,0,0,esf,b8zs
fxsks=1-8
fxols=9-24
loadzone = us
defaultzone=us
Please help Thanks