【问题标题】:asterisk 11.9 issue with read() function and dtmf星号 11.9 与 read() 函数和 dtmf 的问题
【发布时间】:2014-06-17 09:26:11
【问题描述】:

我有两台 asterisk 服务器,一台装有 PBX inflash,另一台仅安装在 CentOS 上的 Asterisk。我需要将这些东西从 PBXINFLASH 迁移到 Asterisk 11.9.0 。 Flash 中的 PbX 正在运行 Asterisk 10.12.1。 我有一个在 Asterisk 10.12.1 上运行良好的拨号方案,但在我的带有 Asterisk 11.9.0 的新盒子上,DTMF 或用户键输入在拨号方案的一部分中不起作用。我曾尝试为 dtmf 进行调试,两台服务器的调试结果都相同,但也很奇怪,这是我在一台机器上的拨号计划工作正常而其他部分工作。拨号计划是呼叫屏幕,其中呼叫者按 1 继续,接收者接听电话,系统要求按 1 接受呼叫或挂断现在一个 Asterisk 11.9.0 呼叫者按 1 输入工作正常,但第二个用户/接收者按 1 不做任何事情。

我正在使用 sip 帐户来测试我的 dtmf。我已经交换了我的 sip 帐户和 sip 软电话来测试仍然是同样的问题。以下是同一宏一半工作和后半部分不接受用户输入的两个部分

前半部分有效并接受用户输入。

exten => _X.,n,GotoIf($[${GROUP_COUNT(${CallerNum})} > 1]?Exceeded) ;Exceeded?
exten => _X.,n,Set(HngupCount=1);Hangup
exten => _X.,n,Flite(Please press 1 to speak with ${destUID})
exten => _X.,n,Read(yesno,sip-silence,1,,2,5)
exten => _X.,n,GotoIf($[${yesno} = 1]?continue:hangup)

下半场不工作或接受用户输入:-

[macro-Dial2]
exten => s,1,Wait(1);ResetCDR
exten => s,n,Set(_StartTime=${STRFTIME(${EPOCH},,%Y-%m-%d %H:%M:%S)})
exten => s,n,ResetCDR
exten => s,n,Set(_RCount=1)
exten => s,n(Repeat),Flite(Hi there)
exten => s,n,Flite(${ARG1} wants to speak to you. Please press 1 to accept the call. 2 to forward the call to voicemail or 3 to reject the call.)
exten => s,n,Flite(we are connecting you)
exten => s,n,Read(ACCEPT,sip-silence,1,,1,5)
exten => s,n,Set(_RCount=$[${RCount} + 1])
exten => s,n,NoOp(Counter is ${RCount} -- the user selected: ${ACCEPT});
exten => s,n,Gotoif($[${ACCEPT} = 1]?accept:vm) ;Accept the call
exten => s,n(vm),Gotoif($[${ACCEPT} = 2]?voicemail:rej) ;forward the call to dummy voicemail (Actually just record the callers message)
exten => s,n(rej),Gotoif($[${ACCEPT} = 3]?reject) ;Reject the call and hangup
exten => s,n,Gotoif($[${RCount} > 2]?reject:Repeat) ; If no key pressed, just hangup the call and inform the User.
exten => s,n(accept),set(SecLeg=${STRFTIME(${EPOCH},,%Y-%m-%d %H:%M:%S)})

在下半场它工作正常,直到以下几行:

exten => s,n,Flite(${ARG1} wants to speak to you. Please press 1 to accept the call. 2 to forward the call to voicemail or 3 to reject the call.)
exten => s,n,Flite(we are connecting you)

【问题讨论】:

  • 能否请您从 AST CLI 发布失败呼叫的文本?我需要看看“AST 看到了什么”才能在这里为您提供帮助。
  • [0K SIP/2.0 200 OK 通过:SIP/2.0/UDP 173.230.137.73:5060;branch=z9hG4bK3d82f078; rport=5060 联系人:<54321><54321><4895>

标签: asterisk agi


【解决方案1】:

注意,只有在所有 flite 消息播放完成后,才会在您的拨号方案中进行用户输入

强烈建议仅由 flite 播放 ${ARG1},而所有其他(静态部分)记录到文件并在 READ 命令中使用

您可以通过在星号中启用 dtmf 调试来获取更多信息。

为此,您需要编辑 logger.conf

【讨论】:

  • 我已经启用了 dtmf 调试,但奇​​怪的是我的工作和非工作星号框都给出了 100% 相同的输出
猜你喜欢
  • 2013-04-14
  • 2014-06-21
  • 2010-10-14
  • 1970-01-01
  • 2012-12-28
  • 2014-05-22
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多