为什么在Dialout并将new uers合并到当前运行的Confbridge Asterik-11.5.1.中时创建了

why new Confbridge created when Dialout and merge New uers into Current running Confbridge Asterisk-11.5.1

本文关键字:Asterik-11 Confbridge 创建 运行 并将 Dialout new uers 合并 为什么      更新时间:2023-10-16

任务:

从当前运行的ConferenceBridge(例如:1010101)拨出并添加Sip用户(例如:我的网络上的Sip/7001)

问题:当我在功能的帮助下使用拨号应用程序拨号时。pbx_exec用户不合并当前正在运行的ConferenceBridge(例如:1010101),而是创建其他新的ConferencyBridge。(例如:名称:conference_bridge->Name)

帮助:如何将conference_bridge->name传递到拨号应用程序字符串中。?

so that new user merge place into current running Conferencebridge
   [macro-CONFDAILOUT]
    exten => s,1,Verbose("================== USER has PICKUPED OR ANSWERED so placed him/her into Conf no : ${ARG1} =================== ")
    ;same => n,Set(MEETME_ROOMNUM=1010101)
    ;same => n,ConfBridge(${MEETME_ROOMNUM},,,conf-admin-sub-dialout)
    same => n,ConfBridge(${ARG1},,,conf-admin-sub-dialout)
    same => n,macroexit()

struct ast_app *dialapp = pbx_findapp("Dial");
char dialstr[100];
char confnum[8];
ast_copy_string(confnum,conference_bridge->name,sizeof(confnum));
ast_verb(3,"n *************Confnum :%s ************n",confnum);
ast_verb(3,"n *************&Confnum :%s ************n",&confnum);
strcpy (dialstr,"SIP");
//strcpy (dialstr,"SIP");
strcat (dialstr,"/");
strcat (dialstr,Sphone);
strcat (dialstr,",");
strcat (dialstr,"30");
strcat (dialstr,",");
//for o/p:1
strcat (dialstr,"hgM(CONFDAILOUT^&confnum)");
//for o/p:2
//strcat (dialstr,"hgM(CONFDAILOUT^&conference_bridge->name)");
ast_verb(3,"n=====Dialing string: '%s' =====n", dialstr);
ast_log(LOG_NOTICE,"n=====Dialing string: '%s' =====n", dialstr);
res=pbx_exec(bridge_channel->chan,dialapp,dialstr);
//res=pbx_exec(bridge_channel->chan,Originate,dialstr);
ast_verb(3,"n ========Return from pbx_exec '%i' n",res);
ast_log(LOG_NOTICE,"n ======Return from pbx_exec '%i'",res);
pbx_builtin_setvar_helper(bridge_channel->chan, "sourcemeetme",conference_bridge->name);
ast_verb(3,"n ====Return from  Disposition: '%s'n",pbx_builtin_getvar_helper(bridge_channel->chan, "DIALSTATUS"));
conference_bridge->name is [1010101]
and &conference_bridge->name:[1010101]
=====Dialing string: 'SIP/7001,30,hgM(CONFDAILOUT^conference_bridge->name)' =====
o/p:1
Conference Bridge Name           Users  Marked Locked?
================================ ====== ====== ========
conference_bridge->name               1      0 unlocked
1010101                               1      1 unlocked
o/p:2
Conference Bridge Name           Users  Marked Locked?
================================ ====== ====== ========
1010101                               1      1 unlocked
&confnum                              1      0 unlocked
                            strcat (dialstr,"CONFDAILOUT");
                            strcat (dialstr,"^");
                            strcat (dialstr,conference_bridge->name);
                            strcat (dialstr,")")

现在新用户Megre进入当前运行的Conference。