Merge branch 'PureCode' of http://x-copper.cn:8418/WolfSpirit/EJM_Display into PureCode
This commit is contained in:
@@ -105,6 +105,7 @@ void P00_PublicPage::WinInit()
|
||||
ui->Label_VoiceWidget->move(32,70+576/2);
|
||||
ui->Label_VoiceWidget->hide();
|
||||
|
||||
<<<<<<< HEAD
|
||||
ui->ButToPage_1->setText(gPageName["P01"]);
|
||||
ui->ButToPage_2->setText(gPageName["P02"]);
|
||||
ui->ButToPage_3->setText(gPageName["P03"]);
|
||||
@@ -121,6 +122,24 @@ void P00_PublicPage::WinInit()
|
||||
ui->ButToPage_14->setText(gPageName["P14"]);
|
||||
ui->ButToPage_15->setText(gPageName["P15"]);
|
||||
ui->ButToPage_16->setText(gPageName["P16"]);
|
||||
=======
|
||||
ui->But_Page_0->setText(gPageName["P01"]);
|
||||
ui->But_Page_1->setText(gPageName["P02"]);
|
||||
ui->But_Page_2->setText(gPageName["P03"]);
|
||||
ui->But_Page_3->setText(gPageName["P04"]);
|
||||
ui->But_Page_4->setText(gPageName["P05"]);
|
||||
ui->But_Page_5->setText(gPageName["P06"]);
|
||||
ui->But_Page_6->setText(gPageName["P07"]);
|
||||
ui->But_Page_7->setText(gPageName["P08"]);
|
||||
ui->But_Page_8->setText(gPageName["P09"]);
|
||||
ui->But_Page_9->setText(gPageName["P10"]);
|
||||
ui->But_Page_10->setText(gPageName["P11"]);
|
||||
ui->But_Page_11->setText(gPageName["P12.0"]);
|
||||
ui->But_Page_12->setText(gPageName["P13"]);
|
||||
ui->But_Page_13->setText(gPageName["P14"]);
|
||||
ui->But_Page_14->setText(gPageName["P15"]);
|
||||
ui->But_Page_15->setText(gPageName["P16"]);
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 初始化定时器(作为成员变量)
|
||||
UIRefresh_Timer = new QTimer(this);
|
||||
@@ -302,6 +321,7 @@ void P00_PublicPage::on_But_Close_clicked()
|
||||
qApp->quit();
|
||||
}
|
||||
// 页面切换实现
|
||||
<<<<<<< HEAD
|
||||
void P00_PublicPage::on_ButToPage_1_clicked(){ ChangePage( 0, 1, "P01");}
|
||||
void P00_PublicPage::on_ButToPage_2_clicked(){ ChangePage( 1, 2, "P02");}
|
||||
void P00_PublicPage::on_ButToPage_3_clicked(){ ChangePage( 2, 301, "P03");}
|
||||
@@ -318,12 +338,34 @@ void P00_PublicPage::on_ButToPage_13_clicked(){ ChangePage(12, 13, "P13");}
|
||||
void P00_PublicPage::on_ButToPage_14_clicked(){ ChangePage(13, 14, "P14");}
|
||||
void P00_PublicPage::on_ButToPage_15_clicked(){ ChangePage(14, 15, "P15");}
|
||||
void P00_PublicPage::on_ButToPage_16_clicked(){ ChangePage(15, 16, "P16");}
|
||||
=======
|
||||
void P00_PublicPage::on_But_Page_0_clicked(){ ChangePage( 0, 1, "P01");}
|
||||
void P00_PublicPage::on_But_Page_1_clicked(){ ChangePage( 1, 2, "P02");}
|
||||
void P00_PublicPage::on_But_Page_2_clicked(){ ChangePage( 2, 301, "P03");}
|
||||
void P00_PublicPage::on_But_Page_3_clicked(){ ChangePage( 3, 401, "P04");}
|
||||
void P00_PublicPage::on_But_Page_4_clicked(){ ChangePage( 4, 501, "P05");}
|
||||
void P00_PublicPage::on_But_Page_5_clicked(){ ChangePage( 5, 601, "P06");}
|
||||
void P00_PublicPage::on_But_Page_6_clicked(){ ChangePage( 6, 7, "P07");}
|
||||
void P00_PublicPage::on_But_Page_7_clicked(){ ChangePage( 7, 8, "P08");}
|
||||
void P00_PublicPage::on_But_Page_8_clicked(){ ChangePage( 8, 9, "P09");}
|
||||
void P00_PublicPage::on_But_Page_9_clicked(){ ChangePage( 9, 10, "P10");}
|
||||
void P00_PublicPage::on_But_Page_10_clicked(){ ChangePage(10, 11, "P11");}
|
||||
void P00_PublicPage::on_But_Page_11_clicked(){ ChangePage(11, 12, gPageIndexStr12);}
|
||||
void P00_PublicPage::on_But_Page_12_clicked(){ ChangePage(12, 13, "P13");}
|
||||
void P00_PublicPage::on_But_Page_13_clicked(){ ChangePage(13, 14, "P14");}
|
||||
void P00_PublicPage::on_But_Page_14_clicked(){ ChangePage(14, 15, "P15");}
|
||||
void P00_PublicPage::on_But_Page_15_clicked(){ ChangePage(15, 16, "P16");}
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
void P00_PublicPage::ChangePage(uint16_t PageIndex,uint16_t PageNum,QString PageName){
|
||||
smoothScrollTo(PageIndex);
|
||||
m_opcManager->writeNodeValue("PageContol.CurrentPage", PageNum,5,100);
|
||||
gPageIndexStr = PageName;
|
||||
if(PageNum != 12){
|
||||
<<<<<<< HEAD
|
||||
ui->ButToPage_12->setText(gPageName[gPageIndexStr12]);
|
||||
=======
|
||||
ui->But_Page_11->setText(gPageName[gPageIndexStr12]);
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
}
|
||||
}
|
||||
/* 1. 读写属性 */
|
||||
|
||||
@@ -357,12 +357,20 @@ void P01_MianPage::UIRefreshTimeOut()
|
||||
TmpBools[9] = getNodeValue("PageBOOLS.B9") .toUInt();
|
||||
|
||||
//杂进度条显示
|
||||
<<<<<<< HEAD
|
||||
QStringList LevelCor = {"color: #ef4444","color: #f59e0b","#22c55e","color: rgb(0, 233, 253)"};
|
||||
=======
|
||||
QStringList LevelCor = {"rgb(255, 0, 0)","rgb(255, 0, 0)","rgb(0, 255, 0)","rgb(0, 255, 255)"};
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
ProgressBar_LCD(ui->PB_SpareTemp,ui->LCD_SpareTemp,"PB_SpareTemp.PageGroup","IN_Sersor.SpareTemp",glMotorTempColor);
|
||||
ProgressBar_LCD(ui->PB_OilLevel,ui->LCD_OilLevel,"PB_OilLevel.PageGroup","IN_Sersor.OilLevel",LevelCor);
|
||||
ProgressBar_LCD(ui->PB_OilTemp,ui->LCD_OilTemp,"PB_OilTemp.PageGroup","IN_Sersor.OilTemp",glMotorTempColor);
|
||||
|
||||
<<<<<<< HEAD
|
||||
QStringList NullColor = {"color: rgb(0, 233, 253)","color: rgb(0, 233, 253)","color: rgb(0, 233, 253)","color: rgb(0, 233, 253)"};
|
||||
=======
|
||||
QStringList NullColor = {"rgb(0, 255, 255)","rgb(0, 255, 255)","rgb(0, 255, 255)","rgb(0, 255, 255)"};
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
ProgressBar_LCD(ui->PB_PressurePump_1,ui->LCD_PressurePump_1,"PB_PressurePump1.PageGroup","IN_Sersor.Pressure_Pump1",NullColor);
|
||||
ProgressBar_LCD(ui->PB_PressurePump_2,ui->LCD_PressurePump_2,"PB_PressurePump2.PageGroup","IN_Sersor.Pressure_Pump2",NullColor);
|
||||
ProgressBar_LCD(ui->PB_PressurePump_3,ui->LCD_PressurePump_3,"PB_PressurePump3.PageGroup","IN_Sersor.Pressure_Pump3",NullColor);
|
||||
@@ -447,6 +455,12 @@ void P01_MianPage::ProgressBar_LCD(QProgressBar *QPB,QLCDNumber *QLCD,QString No
|
||||
QLCD->display(QString::number(Value,'f',2));
|
||||
}
|
||||
void P01_MianPage::PB_Refresh(QString Dev){
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
uint32_t PB_Group1 = getNodeValue("PB_Curr_"+Dev+".PageGroup1") .toUInt();
|
||||
uint32_t PB_Group2 = getNodeValue("PB_Curr_"+Dev+".PageGroup2") .toUInt();
|
||||
uint32_t PB_MotorTemp = getNodeValue("PB_Temp_"+Dev+".PageGroup") .toUInt();
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
uint32_t PB_Group1 = getNodeValue("PB_Curr_"+Dev+".PageGroup1") .toUInt();
|
||||
uint32_t PB_Group2 = getNodeValue("PB_Curr_"+Dev+".PageGroup2") .toUInt();
|
||||
|
||||
@@ -105,9 +105,16 @@ void P08_AlarmPage::UIRefreshTimeOut()
|
||||
uint16_t localOldAlarmCode = m_oldAlarmCode;
|
||||
m_oldAlarmCode = NewAlarmCode;
|
||||
|
||||
<<<<<<< HEAD
|
||||
// 解析设备码 + 索引码
|
||||
uint8_t devCode = NewAlarmCode >> 8; // 高 8 位
|
||||
uint8_t idxCode = NewAlarmCode & 0xFF; // 低 8 位
|
||||
=======
|
||||
uint16_t NewAlarmCode = getNodeValue("AlarmCode.New").toUInt();
|
||||
if (NewAlarmCode == m_oldAlarmCode)
|
||||
return;
|
||||
m_oldAlarmCode = NewAlarmCode;
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 格式化字符串
|
||||
QString timeStr = QDateTime::currentDateTime().toString("MM-dd hh:mm:ss");
|
||||
|
||||
@@ -45,6 +45,7 @@ void P09_RemotePage::UIRefreshTimeOut()
|
||||
{
|
||||
if(gPageIndexStr != "P09")
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
|
||||
// 使用多核心管理器异步获取数据
|
||||
MultiCoreManager::instance()->submitTask([this]() {
|
||||
@@ -81,6 +82,13 @@ void P09_RemotePage::UIRefreshTimeOut()
|
||||
uint16_t dX = map(extractUInt32_8BitPart(AK1,2) + 256,0,512.,0,140)- ui->Label_TransportPos->width()/2;
|
||||
uint16_t dY = map(extractUInt32_8BitPart(AK1,3) + 256,0,512.,0,140)- ui->Label_TransportPos->height()/2;
|
||||
ui->Label_TransportPos->move(dX,dY);
|
||||
=======
|
||||
QString StyleSheetSet;
|
||||
uint32_t DK1 = getNodeValue("PageContol.RemoteDKey1") .toUInt();
|
||||
uint32_t DK2 = getNodeValue("PageContol.RemoteDKey2") .toUInt();
|
||||
uint32_t AK1 = getNodeValue("PageContol.RemoteAKey1") .toUInt();
|
||||
uint32_t AK2 = getNodeValue("PageContol.RemoteAKey2") .toUInt();
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 通用模拟量
|
||||
SetStyle2( ui->Switch_5 , BitMaps().RemUI_SwitchStyles , extractUInt32_8BitPart(AK2,0) < 127 , extractUInt32_8BitPart(AK2,0) > 127 );
|
||||
|
||||
@@ -66,6 +66,18 @@ void P11_IsolationPage::UIRefreshTimeOut()
|
||||
{
|
||||
if(gPageIndexStr != "P11")
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
uint32_t Status = getNodeValue("HMI_LC_Status") .toUInt();
|
||||
qDebug()<<Status;
|
||||
/************************************* 电机基本信息 *************************************/
|
||||
Refresh("Cut" ,1,Status,0,8 ,16);
|
||||
Refresh("Pump" ,2,Status,1,9 ,17);
|
||||
Refresh("Transport" ,3,Status,2,10,18);
|
||||
Refresh("Loader" ,4,Status,3,11,19);
|
||||
Refresh("Standby" ,5,Status,4,12,20);
|
||||
/**************************************************************************************/
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 使用多核心管理器异步处理数据获取和UI更新
|
||||
//MultiCoreManager::instance()->submitTask([this]() {
|
||||
|
||||
@@ -7,7 +7,10 @@
|
||||
#include <QTabWidget>
|
||||
#include <QFileInfo>
|
||||
#include <QPushButton>
|
||||
<<<<<<< HEAD
|
||||
#include <Threads/MultiCoreManager.h>
|
||||
=======
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
class ReadOnlyItem : public QTableWidgetItem
|
||||
{
|
||||
public:
|
||||
@@ -238,6 +241,7 @@ void P12_NetworkPage::UIRefreshTimeOut()
|
||||
{
|
||||
if(!gPageIndexStr.contains("P12"))
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
|
||||
// 使用多核心管理器异步处理数据更新
|
||||
//MultiCoreManager::instance()->submitTask([this]() {
|
||||
@@ -271,6 +275,20 @@ void P12_NetworkPage::UIRefreshTimeOut()
|
||||
QMetaObject::invokeMethod(this, &P12_NetworkPage::UIRefresh_Page0, Qt::QueuedConnection);
|
||||
}
|
||||
//}, "network_page_update_task");
|
||||
=======
|
||||
switch (ui->MainWidget->currentIndex()) {
|
||||
case 0:UIRefresh_Page0();break;
|
||||
case 1:TableViewDataUpdate(ui->TableWidget_PLC_1,&mCsvConfig[0]);break;
|
||||
case 2:TableViewDataUpdate(ui->TableWidget_PLC_2,&mCsvConfig[1]);break;
|
||||
case 3:TableViewDataUpdate(ui->TableWidget_PLC_3,&mCsvConfig[2]);break;
|
||||
case 4:TableViewDataUpdate(ui->TableWidget_PLC_4,&mCsvConfig[3]);break;
|
||||
case 5:TableViewDataUpdate(ui->TableWidget_PLC_5,&mCsvConfig[4]);break;
|
||||
case 6:TableViewDataUpdate(ui->TableWidget_PLC_6,&mCsvConfig[5]);break;
|
||||
case 7:TableViewDataUpdate(ui->TableWidget_PLC_7,&mCsvConfig[6]);break;
|
||||
case 8:TableViewDataUpdate(ui->TableWidget_PLC_8,&mCsvConfig[7]);break;
|
||||
// case 9:TableViewDataUpdate(ui->TableWidget_PLC_9,&mCsvConfig[8]);break;
|
||||
}
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
}
|
||||
|
||||
void P12_NetworkPage::on_But_Network_0_clicked(){ slideToIndex(0, "P12.0");}
|
||||
|
||||
@@ -37,7 +37,7 @@ color: #e0f7fa</string>
|
||||
color: #f3f4f6</string>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
<number>1</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="Nework_0">
|
||||
<property name="styleSheet">
|
||||
@@ -3405,6 +3405,134 @@ QTableWidget::item {
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
<widget class="QWidget" name="Nework_4">
|
||||
<widget class="QTableWidget" name="TableWidget_PLC_4">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1024</width>
|
||||
<height>521</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">/* ====== 2. 整个表格 ====== */
|
||||
QTableWidget {
|
||||
border-image: url(:/Frames/Frames/49.png);
|
||||
gridline-color: cyan; /* 网格线颜色 */
|
||||
color: cyan; /* 默认文字颜色 */
|
||||
outline: 0; /* 去掉选中虚线框 */
|
||||
font: 87 10pt "思源黑体 Heavy";
|
||||
}
|
||||
QTableWidget::item {
|
||||
text-align: center;
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="Nework_5">
|
||||
<widget class="QTableWidget" name="TableWidget_PLC_5">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1024</width>
|
||||
<height>521</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">/* ====== 2. 整个表格 ====== */
|
||||
QTableWidget {
|
||||
border-image: url(:/Frames/Frames/49.png);
|
||||
gridline-color: cyan; /* 网格线颜色 */
|
||||
color: cyan; /* 默认文字颜色 */
|
||||
outline: 0; /* 去掉选中虚线框 */
|
||||
font: 87 10pt "思源黑体 Heavy";
|
||||
}
|
||||
QTableWidget::item {
|
||||
text-align: center;
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="Nework_6">
|
||||
<widget class="QTableWidget" name="TableWidget_PLC_6">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1024</width>
|
||||
<height>521</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">/* ====== 2. 整个表格 ====== */
|
||||
QTableWidget {
|
||||
border-image: url(:/Frames/Frames/49.png);
|
||||
gridline-color: cyan; /* 网格线颜色 */
|
||||
color: cyan; /* 默认文字颜色 */
|
||||
outline: 0; /* 去掉选中虚线框 */
|
||||
font: 87 10pt "思源黑体 Heavy";
|
||||
}
|
||||
QTableWidget::item {
|
||||
text-align: center;
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="Nework_7">
|
||||
<widget class="QTableWidget" name="TableWidget_PLC_7">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1024</width>
|
||||
<height>521</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">/* ====== 2. 整个表格 ====== */
|
||||
QTableWidget {
|
||||
border-image: url(:/Frames/Frames/49.png);
|
||||
gridline-color: cyan; /* 网格线颜色 */
|
||||
color: cyan; /* 默认文字颜色 */
|
||||
outline: 0; /* 去掉选中虚线框 */
|
||||
font: 87 10pt "思源黑体 Heavy";
|
||||
}
|
||||
QTableWidget::item {
|
||||
text-align: center;
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="Nework_8">
|
||||
<widget class="QTableWidget" name="TableWidget_PLC_8">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1024</width>
|
||||
<height>521</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">/* ====== 2. 整个表格 ====== */
|
||||
QTableWidget {
|
||||
border-image: url(:/Frames/Frames/49.png);
|
||||
gridline-color: cyan; /* 网格线颜色 */
|
||||
color: cyan; /* 默认文字颜色 */
|
||||
outline: 0; /* 去掉选中虚线框 */
|
||||
font: 87 10pt "思源黑体 Heavy";
|
||||
}
|
||||
QTableWidget::item {
|
||||
text-align: center;
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
<widget class="QWidget" name="Nework_9"/>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
|
||||
@@ -205,7 +205,11 @@ void P301_PumpPage::UIRefreshTimeOut()
|
||||
for (int i = 0; i < 32; ++i)
|
||||
{
|
||||
// 根据索引查找对应的标签控件
|
||||
<<<<<<< HEAD
|
||||
QLabel* Label = findChild<QLabel*>(QString("Pump_SSConditions_%1").arg(i+1));
|
||||
=======
|
||||
QLabel* Label = findChild<QLabel*>(QString("Text_SSConditions_%1").arg(i+1));
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
// 如果找到标签
|
||||
if (Label){
|
||||
// 基础样式:默认背景图
|
||||
@@ -236,10 +240,17 @@ void P301_PumpPage::UIRefreshTimeOut()
|
||||
}
|
||||
|
||||
void P301_PumpPage::TrailRefreshTimeOut(){
|
||||
<<<<<<< HEAD
|
||||
ui->Pump_CPW_1->appendPoint(0, getNodeValue("IN_PhasePump.Filtered30_U") .toReal());
|
||||
ui->Pump_CPW_1->appendPoint(1, getNodeValue("IN_PhasePump.Filtered30_V") .toReal());
|
||||
ui->Pump_CPW_1->appendPoint(2, getNodeValue("IN_PhasePump.Filtered30_W") .toReal());
|
||||
ui->Pump_CPW_2->appendPoint(0, getNodeValue("IN_PhasePump.Filtered_Temp") .toDouble());
|
||||
=======
|
||||
ui->CPW_1->appendPoint(0, getNodeValue("IN_PhasePump.Filtered30_U") .toReal());
|
||||
ui->CPW_1->appendPoint(1, getNodeValue("IN_PhasePump.Filtered30_V") .toReal());
|
||||
ui->CPW_1->appendPoint(2, getNodeValue("IN_PhasePump.Filtered30_W") .toReal());
|
||||
ui->CPW_2->appendPoint(0, getNodeValue("IN_PhasePump.Filtered_Temp") .toDouble());
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -169,6 +169,7 @@ void P401_CuttingPage::UIRefreshTimeOut()
|
||||
{
|
||||
if(!gPageIndexStr.contains("P04"))
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
|
||||
// 使用多核心管理器异步获取切割页面数据
|
||||
//MultiCoreManager::instance()->submitTask([this]() {
|
||||
@@ -277,6 +278,85 @@ void P401_CuttingPage::TrailRefreshTimeOut(){
|
||||
ui->Cut_CPW_1->appendPoint(1, getNodeValue("IN_PhaseCut.Filtered30_V") .toReal());
|
||||
ui->Cut_CPW_1->appendPoint(2, getNodeValue("IN_PhaseCut.Filtered30_W") .toReal());
|
||||
ui->Cut_CPW_2->appendPoint(0,getNodeValue("IN_PhaseCut.Filtered_Temp") .toDouble());
|
||||
=======
|
||||
/************************************* 电机基本信息 *************************************/
|
||||
// 从OPC节点获取切割设备电机相关的状态数据(32位无符号整数)
|
||||
uint32_t PB_Group1 = getNodeValue("PB_Curr_Cut.PageGroup1").toUInt(); // 电流显示组1数据
|
||||
uint32_t PB_Group2 = getNodeValue("PB_Curr_Cut.PageGroup2").toUInt(); // 电流显示组2数据
|
||||
uint32_t PB_MotorTemp = getNodeValue("PB_Temp_Cut.PageGroup").toUInt(); // 电机温度显示数据
|
||||
uint32_t SSConditions = getNodeValue("StartStopConditions.Cut").toUInt(); // 启停条件状态数据
|
||||
|
||||
// 从32位数据中提取16位百分比值(高16位和低16位拆分)
|
||||
uint16_t PercentageCurU = static_cast<uint16_t>(PB_Group1 >> 16); // U相电流百分比(高16位)
|
||||
uint16_t PercentageCurV = static_cast<uint16_t>(PB_Group1 & 0xFFFF); // V相电流百分比(低16位)
|
||||
uint16_t PercentageCurW = static_cast<uint16_t>(PB_Group2 >> 16); // W相电流百分比(高16位)
|
||||
uint16_t PercentageTmpColor = static_cast<uint16_t>(PB_Group2 & 0xFFFF); // 温度颜色百分比(低16位)
|
||||
uint16_t PercentageMotorTemp= static_cast<uint16_t>(PB_MotorTemp >> 16); // 电机温度百分比(高16位)
|
||||
uint16_t ColorTemp = static_cast<uint16_t>(PB_MotorTemp & 0xFFFF); // 温度颜色值(低16位)
|
||||
|
||||
// 解析颜色值(从百分比中提取个位、十位、百位)
|
||||
uint8_t ColorU = (PercentageTmpColor / 10) % 10; // U相颜色值(十位)
|
||||
uint8_t ColorV = (PercentageTmpColor / 100) % 10; // V相颜色值(百位)
|
||||
uint8_t ColorW = PercentageTmpColor % 10; // W相颜色值(个位)
|
||||
|
||||
// 设置进度条显示(电流和温度)
|
||||
SetProgressBar(ui->PB_Cur_1, PercentageCurU, ColorU, glMotorCurColor); // U相电流进度条
|
||||
SetProgressBar(ui->PB_Cur_2, PercentageCurV, ColorV, glMotorCurColor); // V相电流进度条
|
||||
SetProgressBar(ui->PB_Cur_3, PercentageCurW, ColorW, glMotorCurColor); // W相电流进度条
|
||||
SetProgressBar(ui->PB_Temp, PercentageMotorTemp, ColorTemp, glMotorTempColor); // 电机温度进度条
|
||||
|
||||
// 在LCD上显示实际测量值(电流和温度)
|
||||
ui->LCD_Cur_1->display(getNodeValue("IN_PhaseCut.Filtered30_U").toReal()); // U相电流实际值
|
||||
ui->LCD_Cur_2->display(getNodeValue("IN_PhaseCut.Filtered30_V").toReal()); // V相电流实际值
|
||||
ui->LCD_Cur_3->display(getNodeValue("IN_PhaseCut.Filtered30_W").toReal()); // W相电流实际值
|
||||
ui->LCD_Temp->display(getNodeValue("IN_PhaseCut.Filtered_Temp").toReal()); // 电机温度实际值
|
||||
|
||||
// 更新32个启停条件状态标签的显示样式
|
||||
for (int i = 0; i < 32; ++i)
|
||||
{
|
||||
// 根据索引查找对应的标签控件
|
||||
QLabel* Label = findChild<QLabel*>(QString("Text_SSConditions_%1").arg(i+1));
|
||||
// 如果找到标签
|
||||
if (Label){
|
||||
// 基础样式:默认背景图
|
||||
QString StyleStr = "border-image: url(:/Frames/null.png);\n";
|
||||
|
||||
// 根据状态位设置不同颜色(True/False对应不同样式)
|
||||
StyleStr += getBitOf32Data(SSConditions, i, false) ? TrueColor[i] + "\n" : FalseColor[i] + "\n";
|
||||
// 应用样式到标签
|
||||
|
||||
Label->setStyleSheet(StyleStr);
|
||||
}
|
||||
}
|
||||
/**************************************************************************************/
|
||||
|
||||
|
||||
|
||||
/************************************ 截割油缸压力信息 ***********************************/
|
||||
SetProgressBar(ui->PB_1,ui->LCD_1,"PB_Pressure_Cut.PageGroup","IN_Sersor.Pressure_Cut");
|
||||
/**************************************************************************************/
|
||||
|
||||
/************************************ 掏槽油缸压力信息 ***********************************/
|
||||
SetProgressBar(ui->PB_2,ui->LCD_2,"PB_Pressure_Cutt.PageGroup","IN_Sersor.Pressure_Cutt");
|
||||
/**************************************************************************************/
|
||||
|
||||
/************************************ 截割喷雾压力信息 ***********************************/
|
||||
SetProgressBar(ui->PB_3,ui->LCD_3,"PB_Pressure_CutSpray.PageGroup","IN_Sersor.Pressure_CutSpray");
|
||||
/**************************************************************************************/
|
||||
|
||||
/************************************ 截割喷雾流量信息 ***********************************/
|
||||
SetProgressBar(ui->PB_4,ui->LCD_4,"PB_SprayFlow_Cut.PageGroup","IN_Sersor.SprayFlow_Cut");
|
||||
/**************************************************************************************/
|
||||
|
||||
|
||||
}
|
||||
|
||||
void P401_CuttingPage::TrailRefreshTimeOut(){
|
||||
ui->CPW_1->appendPoint(0, getNodeValue("IN_PhaseCut.Filtered30_U") .toReal());
|
||||
ui->CPW_1->appendPoint(1, getNodeValue("IN_PhaseCut.Filtered30_V") .toReal());
|
||||
ui->CPW_1->appendPoint(2, getNodeValue("IN_PhaseCut.Filtered30_W") .toReal());
|
||||
ui->CPW_2->appendPoint(0,getNodeValue("IN_PhaseCut.Filtered_Temp") .toDouble());
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -246,7 +246,11 @@ void P501_LoaderPage::UIRefreshTimeOut()
|
||||
for (int i = 0; i < 32; ++i)
|
||||
{
|
||||
// 根据索引查找对应的标签控件
|
||||
<<<<<<< HEAD
|
||||
QLabel* Label = findChild<QLabel*>(QString("Loader_SSConditions_%1").arg(i+1));
|
||||
=======
|
||||
QLabel* Label = findChild<QLabel*>(QString("Text_SSConditions_%1").arg(i+1));
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
// 如果找到标签
|
||||
if (Label){
|
||||
// 基础样式:默认背景图
|
||||
@@ -268,6 +272,7 @@ void P501_LoaderPage::UIRefreshTimeOut()
|
||||
}
|
||||
|
||||
void P501_LoaderPage::TrailRefreshTimeOut(){
|
||||
<<<<<<< HEAD
|
||||
ui->Loader_CPW_L1->appendPoint(0, getNodeValue("IN_PhaseLoaderL.Filtered30_U") .toReal());
|
||||
ui->Loader_CPW_L1->appendPoint(1, getNodeValue("IN_PhaseLoaderL.Filtered30_V") .toReal());
|
||||
ui->Loader_CPW_L1->appendPoint(2, getNodeValue("IN_PhaseLoaderL.Filtered30_W") .toReal());
|
||||
@@ -277,6 +282,17 @@ void P501_LoaderPage::TrailRefreshTimeOut(){
|
||||
ui->Loader_CPW_R1->appendPoint(1, getNodeValue("IN_PhaseLoaderR.Filtered30_V") .toReal());
|
||||
ui->Loader_CPW_R1->appendPoint(2, getNodeValue("IN_PhaseLoaderR.Filtered30_W") .toReal());
|
||||
ui->Loader_CPW_R2->appendPoint(0,getNodeValue("IN_PhaseLoaderR.Filtered_Temp") .toDouble());
|
||||
=======
|
||||
ui->CPW_L1->appendPoint(0, getNodeValue("IN_PhaseLoaderL.Filtered30_U") .toReal());
|
||||
ui->CPW_L1->appendPoint(1, getNodeValue("IN_PhaseLoaderL.Filtered30_V") .toReal());
|
||||
ui->CPW_L1->appendPoint(2, getNodeValue("IN_PhaseLoaderL.Filtered30_W") .toReal());
|
||||
ui->CPW_L2->appendPoint(0,getNodeValue("IN_PhaseLoaderL.Filtered_Temp") .toDouble());
|
||||
|
||||
ui->CPW_R1->appendPoint(0, getNodeValue("IN_PhaseLoaderR.Filtered30_U") .toReal());
|
||||
ui->CPW_R1->appendPoint(1, getNodeValue("IN_PhaseLoaderR.Filtered30_V") .toReal());
|
||||
ui->CPW_R1->appendPoint(2, getNodeValue("IN_PhaseLoaderR.Filtered30_W") .toReal());
|
||||
ui->CPW_R2->appendPoint(0,getNodeValue("IN_PhaseLoaderR.Filtered_Temp") .toDouble());
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
}
|
||||
|
||||
void P501_LoaderPage::RotateDev(){
|
||||
|
||||
@@ -246,7 +246,11 @@ void P601_TransportPage::UIRefreshTimeOut()
|
||||
for (int i = 0; i < 32; ++i)
|
||||
{
|
||||
// 根据索引查找对应的标签控件
|
||||
<<<<<<< HEAD
|
||||
QLabel* Label = findChild<QLabel*>(QString("Transport_SSConditions_%1").arg(i+1));
|
||||
=======
|
||||
QLabel* Label = findChild<QLabel*>(QString("Text_SSConditions_%1").arg(i+1));
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
// 如果找到标签
|
||||
if (Label){
|
||||
// 基础样式:默认背景图
|
||||
@@ -263,6 +267,7 @@ void P601_TransportPage::UIRefreshTimeOut()
|
||||
}
|
||||
|
||||
void P601_TransportPage::TrailRefreshTimeOut(){
|
||||
<<<<<<< HEAD
|
||||
ui->Transport_CPW_L1->appendPoint(0, getNodeValue("IN_PhaseTransportL.Filtered30_U") .toReal());
|
||||
ui->Transport_CPW_L1->appendPoint(1, getNodeValue("IN_PhaseTransportL.Filtered30_V") .toReal());
|
||||
ui->Transport_CPW_L1->appendPoint(2, getNodeValue("IN_PhaseTransportL.Filtered30_W") .toReal());
|
||||
@@ -272,6 +277,17 @@ void P601_TransportPage::TrailRefreshTimeOut(){
|
||||
ui->Transport_CPW_R1->appendPoint(1, getNodeValue("IN_PhaseTransportR.Filtered30_V") .toReal());
|
||||
ui->Transport_CPW_R1->appendPoint(2, getNodeValue("IN_PhaseTransportR.Filtered30_W") .toReal());
|
||||
ui->Transport_CPW_R2->appendPoint(0,getNodeValue("IN_PhaseTransportR.Filtered_Temp") .toDouble());
|
||||
=======
|
||||
ui->CPW_L1->appendPoint(0, getNodeValue("IN_PhaseTransportL.Filtered30_U") .toReal());
|
||||
ui->CPW_L1->appendPoint(1, getNodeValue("IN_PhaseTransportL.Filtered30_V") .toReal());
|
||||
ui->CPW_L1->appendPoint(2, getNodeValue("IN_PhaseTransportL.Filtered30_W") .toReal());
|
||||
ui->CPW_L2->appendPoint(0,getNodeValue("IN_PhaseTransportL.Filtered_Temp") .toDouble());
|
||||
|
||||
ui->CPW_R1->appendPoint(0, getNodeValue("IN_PhaseTransportR.Filtered30_U") .toReal());
|
||||
ui->CPW_R1->appendPoint(1, getNodeValue("IN_PhaseTransportR.Filtered30_V") .toReal());
|
||||
ui->CPW_R1->appendPoint(2, getNodeValue("IN_PhaseTransportR.Filtered30_W") .toReal());
|
||||
ui->CPW_R2->appendPoint(0,getNodeValue("IN_PhaseTransportR.Filtered_Temp") .toDouble());
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
}
|
||||
|
||||
void P601_TransportPage::RotateDev(){
|
||||
|
||||
@@ -47,6 +47,7 @@ void P901_RemotePage::UIRefreshTimeOut()
|
||||
{
|
||||
if(gPageIndexStr != "P09")
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
|
||||
// 使用多核心管理器异步获取数据
|
||||
//MultiCoreManager::instance()->submitTask([this]() {
|
||||
@@ -83,6 +84,13 @@ void P901_RemotePage::UIRefreshTimeOut()
|
||||
uint16_t dX = map(extractUInt32_8BitPart(AK1,2) + 256,0,512.,0,140)- ui->Label_TransportPos->width()/2;
|
||||
uint16_t dY = map(extractUInt32_8BitPart(AK1,3) + 256,0,512.,0,140)- ui->Label_TransportPos->height()/2;
|
||||
ui->Label_TransportPos->move(dX,dY);
|
||||
=======
|
||||
QString StyleSheetSet;
|
||||
uint32_t DK1 = getNodeValue("PageContol.RemoteDKey1") .toUInt();
|
||||
uint32_t DK2 = getNodeValue("PageContol.RemoteDKey2") .toUInt();
|
||||
uint32_t AK1 = getNodeValue("PageContol.RemoteAKey1") .toUInt();
|
||||
uint32_t AK2 = getNodeValue("PageContol.RemoteAKey2") .toUInt();
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 通用模拟量
|
||||
SetStyle2( ui->Switch_5 , BitMaps().RemUI_SwitchStyles , extractUInt32_8BitPart(AK2,0) < 127 , extractUInt32_8BitPart(AK2,0) > 127 );
|
||||
|
||||
@@ -47,6 +47,7 @@ void P902_RemotePage::UIRefreshTimeOut()
|
||||
{
|
||||
if(gPageIndexStr != "P09")
|
||||
return;
|
||||
<<<<<<< HEAD
|
||||
|
||||
// 使用多核心管理器异步获取数据
|
||||
//MultiCoreManager::instance()->submitTask([this]() {
|
||||
@@ -83,6 +84,13 @@ void P902_RemotePage::UIRefreshTimeOut()
|
||||
uint16_t dX = map(extractUInt32_8BitPart(AK1,2) + 256,0,512.,0,140)- ui->Label_TransportPos->width()/2;
|
||||
uint16_t dY = map(extractUInt32_8BitPart(AK1,3) + 256,0,512.,0,140)- ui->Label_TransportPos->height()/2;
|
||||
ui->Label_TransportPos->move(dX,dY);
|
||||
=======
|
||||
QString StyleSheetSet;
|
||||
uint32_t DK1 = getNodeValue("PageContol.RemoteDKey1") .toUInt();
|
||||
uint32_t DK2 = getNodeValue("PageContol.RemoteDKey2") .toUInt();
|
||||
uint32_t AK1 = getNodeValue("PageContol.RemoteAKey1") .toUInt();
|
||||
uint32_t AK2 = getNodeValue("PageContol.RemoteAKey2") .toUInt();
|
||||
>>>>>>> f88b815723b08bbfe04dcdec05fc5555cef9352c
|
||||
|
||||
// 通用模拟量
|
||||
SetStyle2( ui->Switch_5 , BitMaps().RemUI_SwitchStyles , extractUInt32_8BitPart(AK2,0) < 127 , extractUInt32_8BitPart(AK2,0) > 127 );
|
||||
|
||||
Reference in New Issue
Block a user