extensions.conf
我可以获得运行 AGI 的呼叫,但是当我的 Perl 脚本运行其循环时,我无法继续运行拨号计划。
所以我需要在拨打电话时在后台运行这个 AGI。
我的 AGI 中搞砸的部分:
{
my $linestatus = $agi->channel_status();
###THIS PART NEEDS TO LOOP UNTIL $linestatus == 6
###But It is also stopping the number from dialling.
do{
}
until($linestatus == 6);
my $query = $collection->insert({
caller => $num,
callername => $name,
linestatus => $linestatus,
extension => $ext,
call_start => $time }, {safe => 1});
$agi->verbose("ANSWERED\n", 1);
}
我的extensions.conf
拨号方案:
exten => _08.,1,AGI(bTel.agi)
exten => _08.,n,Dial(SIP/61${EXTEN:1}@SIPINTERNAL,,tTor)
exten => _08.,n,Hungup