|
|
@@ -723,7 +723,24 @@ int g_switch_set_all_start_time_delay(void* manger,int ntype,int saddr,unsigned
|
|
|
return ret;
|
|
|
}
|
|
|
}
|
|
|
- else
|
|
|
+ else if (__globalDeviceManage._globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Two)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1) + 1, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1) + 1, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
{
|
|
|
ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
if (ret < 0)
|
|
|
@@ -736,6 +753,27 @@ int g_switch_set_all_start_time_delay(void* manger,int ntype,int saddr,unsigned
|
|
|
|
|
|
return 0;
|
|
|
}
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
+ {
|
|
|
+ int ret = 0;
|
|
|
+
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1) + 4, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_start_time_delay(manger, saddr, (chn - 1) + 4, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
case AC_MULTI_S_TYPE:
|
|
|
case AC_MULTI_B_TYPE:
|
|
|
case DC_IN_TYPE:
|
|
|
@@ -800,6 +838,23 @@ int g_switch_set_all_stop_time_delay(void* manger,int ntype,int saddr,unsigned c
|
|
|
return ret;
|
|
|
}
|
|
|
}
|
|
|
+ else if (__globalDeviceManage._globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Two)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) * 3, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) * 3, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) * 3 + 1, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) * 3 + 1, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ }
|
|
|
else
|
|
|
{
|
|
|
ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1), time / 1000);
|
|
|
@@ -812,6 +867,27 @@ int g_switch_set_all_stop_time_delay(void* manger,int ntype,int saddr,unsigned c
|
|
|
}
|
|
|
return 0;
|
|
|
}
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
+ {
|
|
|
+ int ret = 0;
|
|
|
+
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) , time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) , time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) + 4, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ {
|
|
|
+ ret = g_switch_set_t_ac_stop_time_delay(manger, saddr, (chn - 1) + 4, time / 1000);
|
|
|
+ if (ret < 0)
|
|
|
+ return ret;
|
|
|
+ }
|
|
|
+
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
case AC_MULTI_S_TYPE:
|
|
|
case AC_MULTI_B_TYPE:
|
|
|
case DC_IN_TYPE:
|
|
|
@@ -877,6 +953,7 @@ int g_switch_set_all_chn_ctrl(void* manger,GlobalPowerManger* _globalPowerManger
|
|
|
}
|
|
|
break;
|
|
|
case TREE_AC_TYPE:
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
{
|
|
|
int t_ac_CtrlType=0;
|
|
|
int nRet = 0;
|
|
|
@@ -885,7 +962,7 @@ int g_switch_set_all_chn_ctrl(void* manger,GlobalPowerManger* _globalPowerManger
|
|
|
{
|
|
|
t_ac_CtrlType=_globalTACManager->product_ph_outputType;
|
|
|
}
|
|
|
- if (t_ac_CtrlType == 2&&__globalDeviceManage._globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Tree)
|
|
|
+ if ((t_ac_CtrlType == 2&&__globalDeviceManage._globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Tree)||(t_ac_CtrlType == 2&&__globalDeviceManage._globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Two))
|
|
|
{
|
|
|
unsigned short phsts=0;
|
|
|
|
|
|
@@ -1033,6 +1110,7 @@ int g_switch_set_all_ctrl(void* manger,int ntype,int saddr,unsigned short sts)
|
|
|
}
|
|
|
break;
|
|
|
case TREE_AC_TYPE:
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
{
|
|
|
return g_switch_set_t_ac_ctrl(manger, saddr,switch_ctrl);
|
|
|
}
|
|
|
@@ -1083,6 +1161,7 @@ int g_switch_set_all_single_threshold(void* manger,int ntype,int saddr,char chn,
|
|
|
}
|
|
|
break;
|
|
|
case TREE_AC_TYPE:
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
{
|
|
|
if (chn == 0)
|
|
|
{
|
|
|
@@ -1175,6 +1254,7 @@ int g_switch_get_all_out_info(void* manger,int ntype,int saddr,int nNumb,PowerIn
|
|
|
return g_switch_get_dcpdu_all_out_info(manger, saddr, nNumb, _power, _warning);
|
|
|
}
|
|
|
break;
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
case TREE_AC_TYPE:
|
|
|
{
|
|
|
return g_switch_get_t_ac_all_out_info(manger, saddr, nNumb, _power, _warning);
|
|
|
@@ -1204,6 +1284,7 @@ int g_switch_get_all_reset(void* manger,int ntype,int saddr)
|
|
|
return g_switch_set_dcpdu_reset(manger, saddr);
|
|
|
}
|
|
|
break;
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
case TREE_AC_TYPE:
|
|
|
{
|
|
|
return g_switch_set_t_ac_reset(manger, saddr);
|
|
|
@@ -2158,10 +2239,10 @@ int g_switch_set_t_ac_stop_time_delay(void* manger,int saddr,int ch, unsigned in
|
|
|
int g_switch_set_t_ac_chn_ctrl(void* manger,int saddr,unsigned char chn,unsigned short sts)
|
|
|
{
|
|
|
unsigned int offset = 0;
|
|
|
- if(chn > 3 || chn < 0) return -1;
|
|
|
+ if(chn > 4 || chn < 0) return -1;
|
|
|
unsigned short data_temp[2];
|
|
|
memset(data_temp,0,sizeof(data_temp));
|
|
|
- if(chn>=3)
|
|
|
+ if(chn>=4)
|
|
|
return -1;
|
|
|
offset = _SWITCH_T_AC_CH_OUT_ENABLE+chn;
|
|
|
data_temp[0]=sts;
|
|
|
@@ -2188,10 +2269,10 @@ int g_switch_set_t_ac_phchn_ctrl(void* manger,int saddr,unsigned char chn,unsign
|
|
|
{
|
|
|
//三个一组进行设置
|
|
|
unsigned int offset = 0;
|
|
|
- if(chn > 9 || chn < 0) return -1;
|
|
|
+ if(chn > 12 || chn < 0) return -1;
|
|
|
unsigned short data_temp[2];
|
|
|
memset(data_temp,0,sizeof(data_temp));
|
|
|
- if(chn>=9)
|
|
|
+ if(chn>=12)
|
|
|
return -1;
|
|
|
offset = _SWITCH_T_AC_OUT_ENABLE+chn;
|
|
|
data_temp[0]=sts;
|
|
|
@@ -2618,6 +2699,8 @@ int ResetChmData(int nCtrlType)
|
|
|
int chn = 1;
|
|
|
int type = 0;
|
|
|
int nTac_chn=3;
|
|
|
+ int chnBroad = 1;
|
|
|
+ int nTruePHID = 1;
|
|
|
GlobalDeviceManager* _globalDeviceManager=&__globalDeviceManage;
|
|
|
ProductInfo_t *prod=&_globalDeviceManager->_globalDevInfo.product;
|
|
|
int nGroups=prod->ch_delay;
|
|
|
@@ -2915,9 +2998,12 @@ int ResetChmData(int nCtrlType)
|
|
|
}
|
|
|
break;
|
|
|
case TREE_AC_TYPE: // 三相供电
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
{
|
|
|
- log_i("TreeAC_TYPE!\n");
|
|
|
+ log_i("TreeAC_TYPE! nMaxChn=%d\n",nMaxChn);
|
|
|
GlobalPowerManger *_globalPowerMangerTemp = NULL;
|
|
|
+ chnBroad=chn;
|
|
|
+ nTruePHID = nTac_chn-3+1;
|
|
|
for (size_t j = 0; j < nMaxChn; j++)
|
|
|
{
|
|
|
if (_globalDeviceManager->_globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_One)
|
|
|
@@ -3041,6 +3127,220 @@ int ResetChmData(int nCtrlType)
|
|
|
}
|
|
|
nTac_chn += 1;
|
|
|
}
|
|
|
+ }else if (_globalDeviceManager->_globalDevInfo.product.pwr_type == SmartPDU_Tree_AC_Two)
|
|
|
+ {
|
|
|
+ log_i("TreeAC_TYPE_3-2!\n");//由于三项全部都会进行输出一个控制板存在A4B4,A4C4,B4C4三种情况。所以同一时间
|
|
|
+ int m_HalfChn = nMaxChn / 2;
|
|
|
+ if (j < m_HalfChn)//由于一半通道接L1一半通道接L2所以对半分处理。
|
|
|
+ {
|
|
|
+ _globalPowerMangerTemp = (GlobalPowerManger *)malloc(sizeof(GlobalPowerManger));
|
|
|
+ if (_globalPowerMangerTemp == NULL)
|
|
|
+ {
|
|
|
+ log_e("_globalPowerManger malloc error.\n");
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+ memset(_globalPowerMangerTemp, 0, sizeof(GlobalPowerManger));
|
|
|
+ INIT_LIST_HEAD(&_globalPowerMangerTemp->list_Tree_AC);
|
|
|
+
|
|
|
+ // 查询是否由通道信息
|
|
|
+ ret = dev_get_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id, i,
|
|
|
+ j + 1, // 1*8+j
|
|
|
+ _globalPowerMangerTemp);
|
|
|
+ _globalPowerMangerTemp->product_ch_addr = j + 1;
|
|
|
+ // 未查询到信息 则插入
|
|
|
+ if (ret == -1)
|
|
|
+ {
|
|
|
+ _globalPowerMangerTemp->product_id = _globalDeviceManager->_globalDevInfo.product.id;
|
|
|
+ _globalPowerMangerTemp->product_saddr = i;
|
|
|
+ _globalPowerMangerTemp->product_ch_id = chn;
|
|
|
+ _globalPowerMangerTemp->product_ch_addr = j + 1;
|
|
|
+ sprintf(_globalPowerMangerTemp->product_ch_name, "CH%d", _globalPowerMangerTemp->product_ch_id);
|
|
|
+ _globalPowerMangerTemp->product_ch_type = type;
|
|
|
+ _globalPowerMangerTemp->product_ch_status = 0;
|
|
|
+ _globalPowerMangerTemp->product_ch_NF_status = 0;
|
|
|
+
|
|
|
+ _globalPowerMangerTemp->product_ch_start_delay = 1000 * (chn % nGroups != 0 ? chn % nGroups : nGroups);
|
|
|
+ _globalPowerMangerTemp->product_ch_stop_delay = 1000 * (chn % nGroups != 0 ? chn % nGroups : nGroups);
|
|
|
+
|
|
|
+ if (dev_insert_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id,
|
|
|
+ _globalPowerMangerTemp->product_ch_id,
|
|
|
+ _globalPowerMangerTemp) != 0)
|
|
|
+ {
|
|
|
+ log_e("address %d chn %d data inserted error.\n", i, chn);
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ _globalPowerMangerTemp->product_saddr = i;
|
|
|
+ _globalPowerMangerTemp->product_ch_type = type;
|
|
|
+ if (nCtrlType)
|
|
|
+ {
|
|
|
+ _globalPowerMangerTemp->product_ch_id = chn;
|
|
|
+ sprintf(_globalPowerMangerTemp->product_ch_name, "CH%d", _globalPowerMangerTemp->product_ch_id);
|
|
|
+ if (dev_update_power_manage_genera_info_addr(__globalDeviceManage.db, _globalDeviceManager->_globalDevInfo.product.id, _globalPowerMangerTemp->product_saddr, _globalPowerMangerTemp->product_ch_addr, _globalPowerMangerTemp) != 0)
|
|
|
+ {
|
|
|
+ log_e("update pwr general data err.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 添加到队尾
|
|
|
+ list_add_tail(&_globalPowerMangerTemp->list, &_globalDeviceManager->_globalPowerManger.list);
|
|
|
+ chn += 1;
|
|
|
+ }
|
|
|
+ // 初始化三相子通道信息
|
|
|
+ GlobalTreeACManager *_globalTACManager = NULL;
|
|
|
+ _globalTACManager = (GlobalTreeACManager *)malloc(sizeof(GlobalTreeACManager));
|
|
|
+ if (_globalTACManager == NULL)
|
|
|
+ {
|
|
|
+ log_e("_globalTACManager malloc error.\n");
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+ memset(_globalTACManager, 0, sizeof(GlobalTreeACManager));
|
|
|
+
|
|
|
+
|
|
|
+ int nTac_chnTrue=0;
|
|
|
+ int nTac_ChnTac=nTac_chn-3+1;
|
|
|
+ int nPhType=_globalDeviceManager->pCtrlBoard[i].nLeft_phType;
|
|
|
+ //如果是1则A0+B1差C相,如果是2则A0+C2差B相,如果是3则是B1+C2差A相
|
|
|
+ int sumType = _globalDeviceManager->pCtrlBoard[i].nLeft_phType+_globalDeviceManager->pCtrlBoard[i].nRight_phType;
|
|
|
+ int nPhOtherType=0;
|
|
|
+ switch (sumType)
|
|
|
+ {
|
|
|
+ case 1:nPhOtherType = 2;break;
|
|
|
+ case 2:nPhOtherType = 1;break;
|
|
|
+ case 3:nPhOtherType = 0;break;
|
|
|
+ }
|
|
|
+ //为了保证三个通道位置相同顺序是123,456,789进行区分。如果不这么做会存在156,278,3910的情况
|
|
|
+ if (j >= m_HalfChn)
|
|
|
+ {
|
|
|
+ if(j==m_HalfChn)chn=chnBroad;
|
|
|
+ nTac_chnTrue = (j-m_HalfChn)*3+4+nTruePHID-1;// 2->4,5->7,8->10,11->13()
|
|
|
+ nPhType=_globalDeviceManager->pCtrlBoard[i].nRight_phType;
|
|
|
+ chn+=1;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ nTac_chnTrue = (j)*3+ 3+nTruePHID-1;// 1->3,4->6,7->9,10->12,13->15,16->18u0
|
|
|
+ }
|
|
|
+
|
|
|
+ ret = dev_get_t_ac_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id, i,
|
|
|
+ chn-1, // 1*8+j
|
|
|
+ nTac_chnTrue, // 1*8+j
|
|
|
+ _globalTACManager);
|
|
|
+ if (ret == -1)
|
|
|
+ {
|
|
|
+ _globalTACManager->product_id = _globalDeviceManager->_globalDevInfo.product.id;
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ _globalTACManager->product_ch_id = chn-1;
|
|
|
+ _globalTACManager->product_ch_addr = j + 1;
|
|
|
+ _globalTACManager->product_ph_id =nTac_chnTrue;
|
|
|
+ _globalTACManager->product_ph_type = nPhType;
|
|
|
+ _globalTACManager->product_ph_outputType = 3; // 1三相2单相3二相
|
|
|
+ _globalTACManager->product_ph_outputStatus = 1; // 1输出
|
|
|
+ if (dev_insert_t_ac_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id,
|
|
|
+ _globalTACManager->product_ch_id,
|
|
|
+ _globalTACManager) != 0)
|
|
|
+ {
|
|
|
+ log_e("address %d ph_chn %d data inserted error.\n", i, nTac_chnTrue);
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 绑定到三项通道
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ _globalTACManager->product_ph_type =nPhType;
|
|
|
+ if (nCtrlType)
|
|
|
+ {
|
|
|
+ _globalTACManager->product_ph_id = nTac_chnTrue;
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ if (dev_update_t_ac_power_manage_info(__globalDeviceManage.db, _globalTACManager) != 0)
|
|
|
+ {
|
|
|
+ log_e("update pwr general data err.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 查询所属的三项通道
|
|
|
+ _globalPowerMangerTemp = NULL;
|
|
|
+ list_for_each_entry(_globalPowerMangerTemp, &_globalDeviceManager->_globalPowerManger.list, list)
|
|
|
+ {
|
|
|
+ if (_globalPowerMangerTemp && _globalPowerMangerTemp->product_ch_id == _globalTACManager->product_ch_id)
|
|
|
+ {
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (_globalPowerMangerTemp)
|
|
|
+ {
|
|
|
+ list_add_tail(&_globalTACManager->list_Tree_AC, &_globalPowerMangerTemp->list_Tree_AC);
|
|
|
+ }
|
|
|
+ nTac_chn += 1;
|
|
|
+ if (j>=m_HalfChn)
|
|
|
+ {
|
|
|
+ /*
|
|
|
+ // 由于存在2个已存在通道,只有那个不存在的通道需要额外初始化
|
|
|
+ _globalTACManager = (GlobalTreeACManager *)malloc(sizeof(GlobalTreeACManager));
|
|
|
+ int indexT=nPhOtherType;//其他通道是0和1,此处为2
|
|
|
+ memset(_globalTACManager, 0, sizeof(GlobalTreeACManager));
|
|
|
+ if (_globalTACManager == NULL)
|
|
|
+ {
|
|
|
+ log_e("_globalTACManager malloc error.\n");
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+
|
|
|
+ ret = dev_get_t_ac_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id, i,
|
|
|
+ chn-1,
|
|
|
+ indexT,
|
|
|
+ _globalTACManager);
|
|
|
+ _globalTACManager->product_ch_addr = j + 1;
|
|
|
+ // 未查询到信息 则插入
|
|
|
+ if (ret == -1)
|
|
|
+ {
|
|
|
+ _globalTACManager->product_id = _globalDeviceManager->_globalDevInfo.product.id;
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ _globalTACManager->product_ch_id = chn-1;
|
|
|
+ _globalTACManager->product_ch_addr = j + 1;
|
|
|
+ _globalTACManager->product_ph_id = nTac_chnTrue+1;//3,6,7,11;
|
|
|
+ _globalTACManager->product_ph_type = indexT;
|
|
|
+ _globalTACManager->product_ph_outputType = 3; // 1三相2单相3二相
|
|
|
+ _globalTACManager->product_ph_outputStatus = 2; // 1输出2不输出
|
|
|
+ if (dev_insert_t_ac_power_manage_info(_globalDeviceManager->db,
|
|
|
+ _globalDeviceManager->_globalDevInfo.product.id,
|
|
|
+ _globalTACManager->product_ch_id,
|
|
|
+ _globalTACManager) != 0)
|
|
|
+ {
|
|
|
+ log_e("address %d ph_chn %d data inserted error.\n", i, nTac_chn);
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 绑定到三项通道
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ _globalTACManager->product_ph_type = indexT;
|
|
|
+ if (nCtrlType)
|
|
|
+ {
|
|
|
+ _globalTACManager->product_ph_id = nTac_chnTrue+1;
|
|
|
+ _globalTACManager->product_saddr = i;
|
|
|
+ _globalTACManager->product_ph_type = indexT;
|
|
|
+ if (dev_update_t_ac_power_manage_info(__globalDeviceManage.db, _globalTACManager) != 0)
|
|
|
+ {
|
|
|
+ log_e("update pwr general data err.");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //查询所属的三项通道
|
|
|
+ _globalPowerMangerTemp=NULL;
|
|
|
+ list_for_each_entry(_globalPowerMangerTemp, &_globalDeviceManager->_globalPowerManger.list, list)
|
|
|
+ {
|
|
|
+ if (_globalPowerMangerTemp&&_globalPowerMangerTemp->product_ch_id==_globalTACManager->product_ch_id)
|
|
|
+ {
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (_globalPowerMangerTemp)
|
|
|
+ {
|
|
|
+ list_add_tail(&_globalTACManager->list_Tree_AC, &_globalPowerMangerTemp->list_Tree_AC);
|
|
|
+ }
|
|
|
+ */
|
|
|
+ nTac_chn += 1;
|
|
|
+ }
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
@@ -3187,6 +3487,7 @@ int g_switch_get_breaker_info(void* manger,int ntype,int saddr,GlobalBreakerMana
|
|
|
case DCPDU_TYPE:
|
|
|
break;
|
|
|
case TREE_AC_TYPE:
|
|
|
+ case DOUBLE_AC_TYPE:
|
|
|
{
|
|
|
return g_switch_get_t_ac_breaker_info(manger, saddr, _breaker);
|
|
|
}
|