星号 - 在两部本地电话之间拨号

时间:2015-08-04 21:14:04

标签: asterisk pbx

在软电话上,我已将两个帐号tom和paul连接为测试目的。在tom设备上,我拨打了延期100,它在保罗设备上响了。当我接听电话时,我可以听到背景音乐并且没有执行same => n,Playback(demo-moreinfo)

造成这种情况的原因是什么?

我在sip.conf文件中有两个sip中继:

[office-phone](!)
type=friend
context=LocalSets
host=dynamic
nat=yes
secret=password
dtmfmode=auto
disallow=all
allow=ulaw
allow=alaw

[tom](office-phone)
[paul](office-phone)

在extension.conf文件中:

[LocalSets]
exten =>   100,1,Dial(SIP/paul)
same  =>   n,Playback(demo-moreinfo)
same  =>   n,Hangup()

1 个答案:

答案 0 :(得分:1)

[LocalSets]
; Dial connets the callee and caller channels.
exten =>   100,1,Dial(SIP/paul)
; Otherwise Playback is executed (after a Dial timeout occurs)
same  =>   n,Playback(demo-moreinfo)
same  =>   n,Hangup()

就像在这个例子中一样,当呼叫无人接听时,播放vm-nobodyavail声音。

exten => 123,1,Dial(SIP/100,10,m)
;; if the the call is answered, the next priority is never executed
exten => 123,n,Playback(vm-nobodyavail)
exten => 123,n,Hangup()

如果您想播放声音文件,“应答”应用程序会确保连接的频道,下一个优先级可以执行Playback

exten => 100,1,Answer()
exten => 100,n,Playback(demo-moreinfo)

在此示例中,当有人拨打100时,应答将应答呼叫。然后呼叫者将听到声音文件。

exten => 100,1,Answer()
 same => n,Noop("100 answered")
 same => n,Playback(demo-moreinfo)
 ; same => n,Noop("heard the info, dial 200")
 ; same => Dial(SIP/200);
 same => n,Hangup()

您可以在Dial之后执行Playback