如何拨号以从拨号方案内发起呼叫? [英] How to Dial to Originate a Call from Within the Dialplan?

查看:25
本文介绍了如何拨号以从拨号方案内发起呼叫?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

萨尔维特!如何拨打一个号码并让 Asterisk 发起从分机 sipX 到 sipY 的呼叫?

Salvete! How can I dial a number and have Asterisk originate a call from extension sipX to sipY?

sipX 和 sipY 都出现在我的拨号计划的 extensions.conf 中.

Both sipX and sipY appear in extensions.conf of my dialplan.

诀窍是我想在手机上拨打337,然后我的手机不显示图片,然后sipX调用sipY.

The trick is that I want to dial 337 on my phone, and then my phone goes out of the picture, then sipX calls sipY.

假设我希望能够在电话上按下 337,并通过另一部电话的免提电话播放声音,例如闹钟.

Say I want to be able to push 337 on the phone, and have a sound played over the speakerphone of another phone, say, as an alarm.

另一种考虑方式是,我该怎么做:

Another way to consider it is, how can I do this:

  1. 在我的手机上按 337
  2. 完成我的通话,即挂断原来的来电
  3. 即使队列中没有调用也运行宏
  4. 呼叫 sipY
  5. 在 sipY 上播放声音

当运行 #2 操作(完成调用者的会话)并让其余的过程在之后完成时,我们可以使用类似 Asterisk 11 中的预拨号处理程序?

When running the #2 action (completing the caller's session) and letting the rest of the process complete afterward, can we use something like the pre-dial handlers in Asterisk 11?

推荐答案

这就是答案.您将 Answer 作为第一部分,并以hangup"结尾.这会处理忙信号".

Here is the answer. You place Answer as the first part, and end with 'hangup'. That takes care of the "busy signal".

没有通用人工智能.这有效.

No AGI. This works.

[from-internal]
exten => 3334,1,Goto(AngelusBell,startbell,1)


[AngelusBell]
exten => startbell,1,Answer
exten => startbell,n,System(asterisk -rx "channel originate Local/callviking@AngelusBell/n extension playbell@AngelusBell")
exten => startbell,n,Hangup

exten => callviking,1,Dial(SIP/Y,10,D(5))  ;calls my ATA to my paging box and plays 5 tone
exten => callviking,2,Hangup

exten => playbell,1,Answer
exten => playbell,2,Playback(custom/angelusbellWAV)
exten => playbell,3,Hangup

这篇关于如何拨号以从拨号方案内发起呼叫?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆