From b2aa706dfea78ad2e327fb5e414207af69d23d64 Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期六, 13 九月 2025 11:33:04 +0800
Subject: [PATCH] 1.对话框显示工艺参数,可复制到剪贴板; 2.修复几处因按回车或ESC键导致页面被关闭的问题; 3.修复解释警告数据文本失败的问题; 4.更新警告文本,显示警告详细信息; 5.完善警告描述内容 ;
---
Document/AlarmList.csv | 1
SourceCode/Bond/Servo/Servo.vcxproj | 2
SourceCode/Bond/Servo/AlarmManager.cpp | 30 +++-
SourceCode/Bond/Servo/CProcessDataListDlg.cpp | 201 ++++++++++++++++++++++++++++
SourceCode/Bond/Servo/resource.h | 0
Document/ParamInfo.xlsx | 0
SourceCode/Bond/Servo/PageLog.h | 2
SourceCode/Bond/Servo/CProcessDataListDlg.h | 37 +++++
SourceCode/Bond/Servo/PageLog.cpp | 4
SourceCode/Bond/Servo/PageTransferLog.cpp | 13 +
SourceCode/Bond/Servo/Model.cpp | 13 +
SourceCode/Bond/Servo/PageTransferLog.h | 3
SourceCode/Bond/Servo/CPageGlassList.cpp | 24 ++-
SourceCode/Bond/Servo/ListCtrlEx.cpp | 7
SourceCode/Bond/Servo/PageAlarm.h | 4
SourceCode/Bond/Servo/PageRecipe.cpp | 9 +
SourceCode/Bond/Servo/CPageGlassList.h | 3
SourceCode/Bond/Servo/PageAlarm.cpp | 12 +
SourceCode/Bond/Servo/Servo.vcxproj.filters | 2
SourceCode/Bond/Servo/Servo.rc | 0
SourceCode/Bond/x64/Debug/AlarmList.csv | 4
SourceCode/Bond/Servo/PageRecipe.h | 1
22 files changed, 339 insertions(+), 33 deletions(-)
diff --git a/Document/AlarmList.csv b/Document/AlarmList.csv
new file mode 100644
index 0000000..61a6625
--- /dev/null
+++ b/Document/AlarmList.csv
@@ -0,0 +1 @@
+No,UNIT ID,UNIT NO,Alarm Level,Alarm Code,AlarmID,Alarm Text,Description
1,EFEM,100,0,0,1000,机器人CCLink链接异常,"请检查接线,断电重启"
2,EFEM,101,0,0,1001,相机CCLink链接异常,"请检查接线,断电重启"
3,EFEM,102,0,0,1002,静电测试CCLink链接异常,"请检查接线,断电重启"
4,EFEM,103,0,0,1003,,
5,EFEM,104,0,0,1004,,
6,EFEM,105,0,0,1005,,
7,EFEM,106,0,0,1006,,
8,EFEM,107,0,0,1007,,
9,EFEM,108,0,0,1008,,
10,EFEM,109,0,0,1009,,
11,EFEM,110,0,0,1010,总进气气压异常,请检测进气
12,EFEM,111,0,0,1011,总真空气压异常,请检测真空
13,EFEM,112,0,0,1012,LP真空异常,检测真空
14,EFEM,113,0,0,1013,离子风棒压空异常,请检测进气
15,EFEM,114,0,0,1014,机器人真空异常,请检测真空
16,EFEM,115,0,0,1015,急停被按下,请检查急停按钮
17,EFEM,116,0,0,1016,,
18,EFEM,117,0,0,1017,,
19,EFEM,118,0,0,1018,,
20,EFEM,119,0,0,1019,,
21,EFEM,120,0,0,1020,安全门打开,请检查安全门
22,EFEM,121,0,0,1021,正面左门打开中,请检查安全门
23,EFEM,122,0,0,1022,正面右门打开中,请检查安全门
24,EFEM,123,0,0,1023,侧面左门打开中,请检查安全门
25,EFEM,124,0,0,1024,侧面右门打开中,请检查安全门
26,EFEM,125,0,0,1025,背面左门打开中,请检查安全门
27,EFEM,126,0,0,1026,背面右门打开中,请检查安全门
28,EFEM,127,0,0,1027,,
29,EFEM,128,0,0,1028,,
30,EFEM,129,0,0,1029,,
31,EFEM,130,0,0,1030,,
32,EFEM,131,0,0,1031,"Port1_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
33,EFEM,132,0,0,1032,"Port1_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
34,EFEM,133,0,0,1033,"Port1_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
35,EFEM,134,0,0,1034,,
36,EFEM,135,0,0,1035,,
37,EFEM,136,0,0,1036,,
38,EFEM,137,0,0,1037,,
39,EFEM,138,0,0,1038,,
40,EFEM,139,0,0,1039,,
41,EFEM,140,1,0,1040,"Port1_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
42,EFEM,141,1,0,1041,"Port1_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
43,EFEM,142,1,0,1042,"Port1_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
44,EFEM,143,1,0,1043,"Port1_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
45,EFEM,144,0,0,1044,,
46,EFEM,145,0,0,1045,,
47,EFEM,146,0,0,1046,,
48,EFEM,147,0,0,1047,,
49,EFEM,148,0,0,1048,,
50,EFEM,149,0,0,1049,,
51,EFEM,150,0,0,1050,"Port2_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
52,EFEM,151,0,0,1051,"Port2_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
53,EFEM,152,0,0,1052,"Port2_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
54,EFEM,153,0,0,1053,,
55,EFEM,154,0,0,1054,,
56,EFEM,155,0,0,1055,,
57,EFEM,156,0,0,1056,,
58,EFEM,157,0,0,1057,,
59,EFEM,158,0,0,1058,,
60,EFEM,159,0,0,1059,,
61,EFEM,160,0,0,1060,"Port2_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
62,EFEM,161,0,0,1061,"Port2_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
63,EFEM,162,0,0,1062,"Port2_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
64,EFEM,163,0,0,1063,"Port2_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
65,EFEM,164,0,0,1064,,
66,EFEM,165,0,0,1065,,
67,EFEM,166,0,0,1066,,
68,EFEM,167,0,0,1067,,
69,EFEM,168,0,0,1068,,
70,EFEM,169,0,0,1069,,
71,EFEM,170,1,0,1070,,
72,EFEM,171,1,0,1071,"Port3_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
73,EFEM,172,1,0,1072,"Port3_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
74,EFEM,173,1,0,1073,"Port3_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
75,EFEM,174,1,0,1074,"Port3_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
76,EFEM,175,1,0,1075,,
77,EFEM,176,1,0,1076,,
78,EFEM,177,1,0,1077,,
79,EFEM,178,1,0,1078,,
80,EFEM,179,1,0,1079,,
81,EFEM,180,1,0,1080,"Port3_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
82,EFEM,181,1,0,1081,"Port3_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
83,EFEM,182,1,0,1082,"Port3_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
84,EFEM,183,1,0,1083,,
85,EFEM,184,1,0,1084,,
86,EFEM,185,1,0,1085,,
87,EFEM,186,1,0,1086,,
88,EFEM,187,1,0,1087,,
89,EFEM,188,1,0,1088,,
90,EFEM,189,1,0,1089,,
91,EFEM,190,1,0,1090,,
92,EFEM,191,1,0,1091,"Port4_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
93,EFEM,192,1,0,1092,"Port4_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
94,EFEM,193,1,0,1093,"Port4_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
95,EFEM,194,1,0,1094,"Port4_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
96,EFEM,195,1,0,1095,,
97,EFEM,196,1,0,1096,,
98,EFEM,197,1,0,1097,,
99,EFEM,198,1,0,1098,,
100,EFEM,199,1,0,1099,,
101,EFEM,200,1,0,1100,"Port4_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
102,EFEM,201,1,0,1101,"Port4_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
103,EFEM,202,1,0,1102,"Port4_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
104,EFEM,203,1,0,1103,,
105,EFEM,204,1,0,1104,,
106,EFEM,205,1,0,1105,,
107,EFEM,206,1,0,1106,,
108,EFEM,207,1,0,1107,,
109,EFEM,208,1,0,1108,,
110,EFEM,209,1,0,1109,,
111,EFEM,210,0,0,1110,回原点失败/超时,请检查设备状态以及轴位置是否有干涉,请重新执行回原操作
112,EFEM,211,0,0,1111,Flip工位,真空打开时在荷异常,请检查玻璃位置
113,EFEM,212,1,0,1112,,
114,EFEM,213,1,0,1113,,
115,EFEM,214,1,0,1114,,
116,EFEM,215,1,0,1115,,
117,EFEM,216,1,0,1116,,
118,EFEM,217,1,0,1117,,
119,EFEM,218,1,0,1118,,
120,EFEM,219,1,0,1119,,
121,EFEM,220,1,0,1120,任务取消失败,当前取消任务条件不满足
122,EFEM,221,1,0,1121,任务重试失败,当前重试任务条件不满足
\ No newline at end of file
diff --git a/Document/ParamInfo.xlsx b/Document/ParamInfo.xlsx
new file mode 100644
index 0000000..3e237c1
--- /dev/null
+++ b/Document/ParamInfo.xlsx
Binary files differ
diff --git a/SourceCode/Bond/Servo/AlarmManager.cpp b/SourceCode/Bond/Servo/AlarmManager.cpp
index 2143f34..56d6cbb 100644
--- a/SourceCode/Bond/Servo/AlarmManager.cpp
+++ b/SourceCode/Bond/Servo/AlarmManager.cpp
@@ -784,16 +784,33 @@
// 读取报警文件
bool AlarmManager::readAlarmFile(const std::string& filename) {
- std::ifstream file(filename);
- std::string line;
- bool first_line = true;
-
+ std::ifstream file(filename, std::ios::binary);
if (!file.is_open()) {
std::cerr << "Error opening file!" << std::endl;
return false;
}
- while (std::getline(file, line)) {
+ auto getline_cross = [](std::ifstream& f, std::string& out) -> bool {
+ out.clear();
+ char ch;
+ while (f.get(ch)) {
+ if (ch == '\r') {
+ // 处理 \r\n 或 单独 \r
+ if (f.peek() == '\n') f.get();
+ break;
+ }
+ else if (ch == '\n') {
+ break;
+ }
+ out.push_back(ch);
+ }
+ return !out.empty() || !f.eof();
+ };
+
+ std::string line;
+ bool first_line = true;
+
+ while (getline_cross(file, line)) {
if (first_line) {
first_line = false;
continue;
@@ -804,7 +821,6 @@
AlarmInfo alarm;
try {
- // 逐字段解析并验证
if (!std::getline(ss, cell, ',')) throw std::runtime_error("Missing field: No");
if (!std::getline(ss, alarm.strUnitID, ',')) throw std::runtime_error("Missing field: UnitID");
if (!std::getline(ss, alarm.strUnitNo, ',')) throw std::runtime_error("Missing field: UnitNo");
@@ -817,7 +833,6 @@
if (!std::getline(ss, alarm.strAlarmText, ',')) throw std::runtime_error("Missing field: AlarmText");
if (!std::getline(ss, alarm.strDescription, ',')) throw std::runtime_error("Missing field: Description");
- // 检查是否重复
if (m_mapAlarm.find(alarm.nAlarmID) == m_mapAlarm.end()) {
m_mapAlarm[alarm.nAlarmID] = alarm;
}
@@ -826,7 +841,6 @@
}
}
catch (const std::exception& e) {
- // 捕获并记录解析错误
std::cerr << "Error parsing line: " << line << " - " << e.what() << std::endl;
continue;
}
diff --git a/SourceCode/Bond/Servo/CPageGlassList.cpp b/SourceCode/Bond/Servo/CPageGlassList.cpp
index d85afe4..4291a7e 100644
--- a/SourceCode/Bond/Servo/CPageGlassList.cpp
+++ b/SourceCode/Bond/Servo/CPageGlassList.cpp
@@ -8,12 +8,12 @@
#include "GlassJson.h"
#include "CServoUtilsTool.h"
#include "ToolUnits.h"
-
#include <optional>
#include <unordered_set>
#include <unordered_map>
#include <vector>
#include <string>
+#include "CProcessDataListDlg.h"
#define PAGE_SIZE 50
#define PAGE_BACKGROUND_COLOR RGB(252, 252, 255)
@@ -436,7 +436,7 @@
}
// ===== CPageGlassList 娑堟伅澶勭悊绋嬪簭 =====
-void CPageGlassList::InitRxWindow()
+void CPageGlassList::InitRxWindows()
{
// 璁㈤槄鏁版嵁
IRxWindows* pRxWindows = RX_GetRxWindows();
@@ -946,7 +946,7 @@
{
if (nIDEvent == 1) {
KillTimer(1);
- InitRxWindow();
+ InitRxWindows();
}
else if (nIDEvent == 2) {
UpdateWipData(); // 鍙仛澧為噺锛屼笉閲嶅缓
@@ -1065,10 +1065,11 @@
{
auto* p = reinterpret_cast<NMC_ELC_SHOWFULLTEXT*>(pNMHDR);
- // 杩欓噷鏆傛椂鐢ㄦ秷鎭鏄剧ず锛涘悗缁彲鎹㈡垚浣犵殑璇︽儏椤�
- CString strNewMsg = p->text;
- strNewMsg.Replace(_T(","), _T("\n"));
- MessageBox(strNewMsg, _T("璇︾粏淇℃伅"), MB_OK | MB_ICONINFORMATION);
+ // 瀵硅瘽妗嗘樉绀哄伐鑹哄弬鏁�
+ CProcessDataListDlg dlg;
+ dlg.setRawText(p->text);
+ dlg.DoModal();
+
*pResult = 0;
}
@@ -1395,3 +1396,12 @@
return true;
}
+
+BOOL CPageGlassList::PreTranslateMessage(MSG* pMsg)
+{
+ if (pMsg->wParam == VK_RETURN || pMsg->wParam == VK_ESCAPE) {
+ return TRUE;
+ }
+
+ return CDialogEx::PreTranslateMessage(pMsg);
+}
diff --git a/SourceCode/Bond/Servo/CPageGlassList.h b/SourceCode/Bond/Servo/CPageGlassList.h
index af56f30..1094c50 100644
--- a/SourceCode/Bond/Servo/CPageGlassList.h
+++ b/SourceCode/Bond/Servo/CPageGlassList.h
@@ -40,7 +40,7 @@
bool m_rebuilding = false;
private:
- void InitRxWindow();
+ void InitRxWindows();
void Resize();
void InitStatusCombo();
void InitTimeRangeCombo();
@@ -75,5 +75,6 @@
afx_msg void OnBnClickedButtonPrevPage();
afx_msg void OnBnClickedButtonNextPage();
afx_msg void OnShowFullText(NMHDR* pNMHDR, LRESULT* pResult);
+ virtual BOOL PreTranslateMessage(MSG* pMsg);
DECLARE_MESSAGE_MAP()
};
diff --git a/SourceCode/Bond/Servo/CProcessDataListDlg.cpp b/SourceCode/Bond/Servo/CProcessDataListDlg.cpp
new file mode 100644
index 0000000..65e58dd
--- /dev/null
+++ b/SourceCode/Bond/Servo/CProcessDataListDlg.cpp
@@ -0,0 +1,201 @@
+锘�// CProcessDataListDlg.cpp: 瀹炵幇鏂囦欢
+//
+
+#include "stdafx.h"
+#include "Servo.h"
+#include "CProcessDataListDlg.h"
+#include "afxdialogex.h"
+
+
+// CProcessDataListDlg 瀵硅瘽妗�
+
+IMPLEMENT_DYNAMIC(CProcessDataListDlg, CDialogEx)
+
+CProcessDataListDlg::CProcessDataListDlg(CWnd* pParent /*=nullptr*/)
+ : CDialogEx(IDD_DIALOG_PROCESS_DATA_LIST, pParent)
+{
+
+}
+
+CProcessDataListDlg::~CProcessDataListDlg()
+{
+}
+
+void CProcessDataListDlg::DoDataExchange(CDataExchange* pDX)
+{
+ CDialogEx::DoDataExchange(pDX);
+ DDX_Control(pDX, IDC_LIST_RECIPE_PARAM, m_listCtrl);
+}
+
+
+BEGIN_MESSAGE_MAP(CProcessDataListDlg, CDialogEx)
+ ON_BN_CLICKED(IDC_BUTTON1, &CProcessDataListDlg::OnBnClickedButton1)
+END_MESSAGE_MAP()
+
+
+// CProcessDataListDlg 娑堟伅澶勭悊绋嬪簭
+
+
+BOOL CProcessDataListDlg::OnInitDialog()
+{
+ CDialogEx::OnInitDialog();
+
+
+ DWORD dwStyle = m_listCtrl.GetExtendedStyle();
+ dwStyle |= LVS_EX_FULLROWSELECT;
+ dwStyle |= LVS_EX_GRIDLINES;
+ dwStyle |= LVS_EX_DOUBLEBUFFER;
+ m_listCtrl.SetExtendedStyle(dwStyle);
+
+ HIMAGELIST imageList = ImageList_Create(24, 24, ILC_COLOR24, 1, 1);
+ ListView_SetImageList(m_listCtrl.GetSafeHwnd(), imageList, LVSIL_SMALL);
+ m_listCtrl.InsertColumn(0, _T("鍚嶇О"), LVCFMT_RIGHT, 188);
+ m_listCtrl.InsertColumn(1, _T("鍊�"), LVCFMT_LEFT, 128);
+
+
+ InsertParamsToListCtrl(m_listCtrl, m_strRawText);
+
+ return TRUE; // return TRUE unless you set the focus to a control
+ // 寮傚父: OCX 灞炴�ч〉搴旇繑鍥� FALSE
+}
+
+void CProcessDataListDlg::setRawText(CString& strRawText)
+{
+ m_strRawText = strRawText;
+}
+
+void CProcessDataListDlg::InsertParamsToListCtrl(CListCtrl& listCtrl, const CString& data)
+{
+ // 娓呯┖鐜版湁鍐呭
+ listCtrl.DeleteAllItems();
+
+ int row = 0;
+ int start = 0;
+ CString item;
+
+ // 鎸夐�楀彿鍒嗗壊
+ while (AfxExtractSubString(item, data, row, ',')) // row 浠� 0 寮�濮嬶紝閫愪釜鍙栧瓙涓�
+ {
+ int pos = item.Find(_T(':'));
+ if (pos == -1) {
+ row++;
+ continue;
+ }
+
+ CString name = item.Left(pos);
+ CString value = item.Mid(pos + 1);
+
+ name.Trim(); // 鍘绘帀鍓嶅悗绌烘牸
+ value.Trim();
+
+ int nItem = listCtrl.InsertItem(row, name); // 绗竴鍒楋細鍙傛暟鍚�
+ listCtrl.SetItemText(nItem, 1, value); // 绗簩鍒楋細鍙傛暟鍊�
+
+ row++;
+ }
+}
+
+bool CProcessDataListDlg::CopyListCtrlToClipboard(CListCtrl& listCtrl, bool includeHeader/* = false*/)
+{
+ CString strCSV;
+ int nCount = listCtrl.GetItemCount();
+ int nColCount = listCtrl.GetHeaderCtrl()->GetItemCount();
+
+ if (nCount == 0 || nColCount == 0)
+ return false;
+
+ // 濡傛灉闇�瑕佸鍑鸿〃澶�
+ if (includeHeader)
+ {
+ CString headerLine;
+ for (int j = 0; j < nColCount; j++)
+ {
+ CString text;
+ LVCOLUMN col;
+ TCHAR buf[256] = { 0 };
+ col.mask = LVCF_TEXT;
+ col.pszText = buf;
+ col.cchTextMax = 255;
+ if (listCtrl.GetColumn(j, &col))
+ text = col.pszText;
+
+ if (text.Find(_T(',')) != -1 || text.Find(_T('"')) != -1)
+ {
+ text.Replace(_T("\""), _T("\"\""));
+ text = _T("\"") + text + _T("\"");
+ }
+
+ headerLine += text;
+ if (j < nColCount - 1)
+ headerLine += _T(",");
+ }
+ strCSV += headerLine + _T("\n");
+ }
+
+ // 閬嶅巻琛�
+ for (int i = 0; i < nCount; i++)
+ {
+ CString line;
+ for (int j = 0; j < nColCount; j++)
+ {
+ CString text = listCtrl.GetItemText(i, j);
+
+ // 濡傛灉鍖呭惈閫楀彿鎴栧弻寮曞彿锛屽姞涓婂紩鍙峰苟杞箟
+ if (text.Find(_T(',')) != -1 || text.Find(_T('"')) != -1)
+ {
+ text.Replace(_T("\""), _T("\"\""));
+ text = _T("\"") + text + _T("\"");
+ }
+
+ line += text;
+ if (j < nColCount - 1)
+ line += _T(",");
+ }
+ strCSV += line + _T("\n");
+ }
+
+ if (!OpenClipboard())
+ return false;
+
+ EmptyClipboard();
+
+ // 杞负鍏ㄥ眬鍐呭瓨
+ HGLOBAL hMem = GlobalAlloc(GMEM_MOVEABLE, (strCSV.GetLength() + 1) * sizeof(TCHAR));
+ if (!hMem)
+ {
+ CloseClipboard();
+ return false;
+ }
+
+ LPTSTR pMem = (LPTSTR)GlobalLock(hMem);
+ if (!pMem)
+ {
+ GlobalFree(hMem);
+ CloseClipboard();
+ return false;
+ }
+
+ _tcscpy_s(pMem, strCSV.GetLength() + 1, strCSV);
+ GlobalUnlock(hMem);
+
+#ifdef UNICODE
+ SetClipboardData(CF_UNICODETEXT, hMem);
+#else
+ SetClipboardData(CF_TEXT, hMem);
+#endif
+
+ CloseClipboard();
+ return true;
+}
+
+void CProcessDataListDlg::OnBnClickedButton1()
+{
+ if (CopyListCtrlToClipboard(m_listCtrl, true))
+ {
+ AfxMessageBox(_T("澶嶅埗鎴愬姛锛�"));
+ }
+ else
+ {
+ AfxMessageBox(_T("澶嶅埗澶辫触锛�"));
+ }
+}
diff --git a/SourceCode/Bond/Servo/CProcessDataListDlg.h b/SourceCode/Bond/Servo/CProcessDataListDlg.h
new file mode 100644
index 0000000..a825179
--- /dev/null
+++ b/SourceCode/Bond/Servo/CProcessDataListDlg.h
@@ -0,0 +1,37 @@
+锘�#pragma once
+#include "ListCtrlEx.h"
+
+
+// CProcessDataListDlg 瀵硅瘽妗�
+
+class CProcessDataListDlg : public CDialogEx
+{
+ DECLARE_DYNAMIC(CProcessDataListDlg)
+
+public:
+ CProcessDataListDlg(CWnd* pParent = nullptr); // 鏍囧噯鏋勯�犲嚱鏁�
+ virtual ~CProcessDataListDlg();
+
+public:
+ void setRawText(CString& strRawText);
+ void InsertParamsToListCtrl(CListCtrl& listCtrl, const CString& data);
+ bool CopyListCtrlToClipboard(CListCtrl& listCtrl, bool includeHeader = false);
+
+private:
+ CString m_strRawText;
+ CListCtrlEx m_listCtrl;
+
+
+// 瀵硅瘽妗嗘暟鎹�
+#ifdef AFX_DESIGN_TIME
+ enum { IDD = IDD_DIALOG_PROCESS_DATA_LIST };
+#endif
+
+protected:
+ virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 鏀寔
+
+ DECLARE_MESSAGE_MAP()
+public:
+ virtual BOOL OnInitDialog();
+ afx_msg void OnBnClickedButton1();
+};
diff --git a/SourceCode/Bond/Servo/ListCtrlEx.cpp b/SourceCode/Bond/Servo/ListCtrlEx.cpp
index ff94bd7..ea06fcb 100644
--- a/SourceCode/Bond/Servo/ListCtrlEx.cpp
+++ b/SourceCode/Bond/Servo/ListCtrlEx.cpp
@@ -34,12 +34,13 @@
{
// 根据在 SetItemColor(DWORD iItem, COLORREF color) 设置的
// ITEM号和COLORREF 在摸板中查找,然后进行颜色赋值。
+ /*
LISTITEMEX_9& itemex = m_listItemColor.GetAt(m_listItemColor.FindIndex(nmcd.dwItemSpec));
lplvdr->clrText = itemex.colText;
lplvdr->clrTextBk = itemex.colTextBk;
*pResult = CDRF_DODEFAULT;
-
- /*
+ */
+
if (nmcd.dwItemSpec % 2 == 0) {
lplvdr->clrText = RGB(0, 0, 0);
lplvdr->clrTextBk = RGB(235, 235, 235);
@@ -50,7 +51,7 @@
lplvdr->clrTextBk = RGB(255, 255, 255);
*pResult = CDRF_DODEFAULT;
}
- */
+
break;
}
diff --git a/SourceCode/Bond/Servo/Model.cpp b/SourceCode/Bond/Servo/Model.cpp
index a518901..8d987b6 100644
--- a/SourceCode/Bond/Servo/Model.cpp
+++ b/SourceCode/Bond/Servo/Model.cpp
@@ -250,9 +250,18 @@
alarmData.strUnitName = alarmManager.getUnitNameById(alarmData.nDeviceId, alarmData.nUnitId);
alarmData.strStartTime = CToolUnits::timeToString2(CToolUnits::getTimestamp());
alarmData.strEndTime = "";
-
+ alarmData.strDescription = "";
+
const AlarmInfo* alarmInfo = alarmManager.getAlarmInfoByID(alarmData.nId);
- alarmData.strDescription = alarmInfo != nullptr ? alarmInfo->strAlarmText : "";
+ if (alarmInfo != nullptr) {
+ if (alarmInfo->strDescription.empty()) {
+ alarmData.strDescription = alarmInfo->strAlarmText;
+ }
+ else {
+ alarmData.strDescription = alarmInfo->strAlarmText + "," + alarmInfo->strDescription + ".";
+ }
+ }
+
int nAlarmEventId = 0;
bool result = alarmManager.addAlarm(alarmData, nAlarmEventId);
diff --git a/SourceCode/Bond/Servo/PageAlarm.cpp b/SourceCode/Bond/Servo/PageAlarm.cpp
index af5b619..dd6a8e4 100644
--- a/SourceCode/Bond/Servo/PageAlarm.cpp
+++ b/SourceCode/Bond/Servo/PageAlarm.cpp
@@ -48,7 +48,7 @@
}
}
-void CPageAlarm::InitRxWindow()
+void CPageAlarm::InitRxWindows()
{
/* code */
// 璁㈤槄鏁版嵁
@@ -249,6 +249,7 @@
BOOL CPageAlarm::OnInitDialog()
{
CDialogEx::OnInitDialog();
+ InitRxWindows();
SetTimer(1, 3000, nullptr);
// 涓嬫媺妗嗘帶浠�
@@ -506,3 +507,12 @@
m_nCurPage++;
UpdatePageData(); // 璋冪敤鍒嗛〉鏇存柊鍑芥暟
}
+
+BOOL CPageAlarm::PreTranslateMessage(MSG* pMsg)
+{
+ if (pMsg->wParam == VK_RETURN || pMsg->wParam == VK_ESCAPE) {
+ return TRUE;
+ }
+
+ return CDialogEx::PreTranslateMessage(pMsg);
+}
diff --git a/SourceCode/Bond/Servo/PageAlarm.h b/SourceCode/Bond/Servo/PageAlarm.h
index 783ce29..6d9710c 100644
--- a/SourceCode/Bond/Servo/PageAlarm.h
+++ b/SourceCode/Bond/Servo/PageAlarm.h
@@ -17,7 +17,7 @@
virtual ~CPageAlarm();
private:
- void InitRxWindow();
+ void InitRxWindows();
void Resize();
void LoadAlarms();
void UpdatePageData();
@@ -63,11 +63,11 @@
afx_msg void OnDestroy();
afx_msg void OnClose();
afx_msg void OnSize(UINT nType, int cx, int cy);
- afx_msg void OnTimer(UINT_PTR nIDEvent);
afx_msg void OnCbnSelchangeComboDatetime();
afx_msg void OnBnClickedButtonSearch();
afx_msg void OnBnClickedButtonExport();
afx_msg void OnBnClickedButtonPrevPage();
afx_msg void OnBnClickedButtonNextPage();
+ virtual BOOL PreTranslateMessage(MSG* pMsg);
DECLARE_MESSAGE_MAP()
};
diff --git a/SourceCode/Bond/Servo/PageLog.cpp b/SourceCode/Bond/Servo/PageLog.cpp
index c5cd4a9..98bcfae 100644
--- a/SourceCode/Bond/Servo/PageLog.cpp
+++ b/SourceCode/Bond/Servo/PageLog.cpp
@@ -53,7 +53,7 @@
// CLogDlg 消息处理程序
-void CPageLog::InitRxWindow()
+void CPageLog::InitRxWindows()
{
/* code */
// 订阅数据
@@ -116,7 +116,7 @@
BOOL CPageLog::OnInitDialog()
{
CDialogEx::OnInitDialog();
- InitRxWindow();
+ InitRxWindows();
// 缓存
diff --git a/SourceCode/Bond/Servo/PageLog.h b/SourceCode/Bond/Servo/PageLog.h
index 4e373d2..3cf2753 100644
--- a/SourceCode/Bond/Servo/PageLog.h
+++ b/SourceCode/Bond/Servo/PageLog.h
@@ -25,7 +25,7 @@
private:
- void InitRxWindow();
+ void InitRxWindows();
void AppendLog(int level, const char* pszText);
void Resize();
diff --git a/SourceCode/Bond/Servo/PageRecipe.cpp b/SourceCode/Bond/Servo/PageRecipe.cpp
index 8984870..cf387ce 100644
--- a/SourceCode/Bond/Servo/PageRecipe.cpp
+++ b/SourceCode/Bond/Servo/PageRecipe.cpp
@@ -778,4 +778,13 @@
}
}
return result;
+}
+
+BOOL CPageRecipe::PreTranslateMessage(MSG* pMsg)
+{
+ if (pMsg->wParam == VK_RETURN || pMsg->wParam == VK_ESCAPE) {
+ return TRUE;
+ }
+
+ return CDialogEx::PreTranslateMessage(pMsg);
}
\ No newline at end of file
diff --git a/SourceCode/Bond/Servo/PageRecipe.h b/SourceCode/Bond/Servo/PageRecipe.h
index eac7fb3..1ca4b99 100644
--- a/SourceCode/Bond/Servo/PageRecipe.h
+++ b/SourceCode/Bond/Servo/PageRecipe.h
@@ -46,6 +46,7 @@
afx_msg void OnClickListPPID(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnDblclkListPPID(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnCbnSelchangeComboEquipment();
+ virtual BOOL PreTranslateMessage(MSG* pMsg);
DECLARE_MESSAGE_MAP()
private:
diff --git a/SourceCode/Bond/Servo/PageTransferLog.cpp b/SourceCode/Bond/Servo/PageTransferLog.cpp
index 978a8e0..9ec52d4 100644
--- a/SourceCode/Bond/Servo/PageTransferLog.cpp
+++ b/SourceCode/Bond/Servo/PageTransferLog.cpp
@@ -51,7 +51,7 @@
CDialogEx::DoDataExchange(pDX);
}
-void CPageTransferLog::InitRxWindow()
+void CPageTransferLog::InitRxWindows()
{
/* code */
// 璁㈤槄鏁版嵁
@@ -408,7 +408,7 @@
{
if (nIDEvent == 1) {
KillTimer(1);
- InitRxWindow();
+ InitRxWindows();
}
CDialogEx::OnTimer(nIDEvent);
}
@@ -497,4 +497,13 @@
m_nCurPage++;
UpdatePageData();
}
+}
+
+BOOL CPageTransferLog::PreTranslateMessage(MSG* pMsg)
+{
+ if (pMsg->wParam == VK_RETURN || pMsg->wParam == VK_ESCAPE) {
+ return TRUE;
+ }
+
+ return CDialogEx::PreTranslateMessage(pMsg);
}
\ No newline at end of file
diff --git a/SourceCode/Bond/Servo/PageTransferLog.h b/SourceCode/Bond/Servo/PageTransferLog.h
index 1a26e90..3cb3f0c 100644
--- a/SourceCode/Bond/Servo/PageTransferLog.h
+++ b/SourceCode/Bond/Servo/PageTransferLog.h
@@ -36,7 +36,7 @@
CDateTimeCtrl m_dateTimeEnd;
CListCtrlEx m_listCtrl;
- void InitRxWindow();
+ void InitRxWindows();
void Resize();
void InitStatusCombo();
void InitTimeRangeCombo();
@@ -66,5 +66,6 @@
afx_msg void OnBnClickedButtonExport();
afx_msg void OnBnClickedButtonPrevPage();
afx_msg void OnBnClickedButtonNextPage();
+ virtual BOOL PreTranslateMessage(MSG* pMsg);
DECLARE_MESSAGE_MAP()
};
diff --git a/SourceCode/Bond/Servo/Servo.rc b/SourceCode/Bond/Servo/Servo.rc
index 85262f2..f4782c3 100644
--- a/SourceCode/Bond/Servo/Servo.rc
+++ b/SourceCode/Bond/Servo/Servo.rc
Binary files differ
diff --git a/SourceCode/Bond/Servo/Servo.vcxproj b/SourceCode/Bond/Servo/Servo.vcxproj
index c14513f..3022283 100644
--- a/SourceCode/Bond/Servo/Servo.vcxproj
+++ b/SourceCode/Bond/Servo/Servo.vcxproj
@@ -225,6 +225,7 @@
<ClInclude Include="CPageReport.h" />
<ClInclude Include="CPageVarialbles.h" />
<ClInclude Include="CParam.h" />
+ <ClInclude Include="CProcessDataListDlg.h" />
<ClInclude Include="CReport.h" />
<ClInclude Include="CRobotCmdContainerDlg.h" />
<ClInclude Include="CRobotCmdTestDlg.h" />
@@ -400,6 +401,7 @@
<ClCompile Include="CPageReport.cpp" />
<ClCompile Include="CPageVarialbles.cpp" />
<ClCompile Include="CParam.cpp" />
+ <ClCompile Include="CProcessDataListDlg.cpp" />
<ClCompile Include="CReport.cpp" />
<ClCompile Include="CRobotCmdContainerDlg.cpp" />
<ClCompile Include="CRobotCmdTestDlg.cpp" />
diff --git a/SourceCode/Bond/Servo/Servo.vcxproj.filters b/SourceCode/Bond/Servo/Servo.vcxproj.filters
index e596b71..796971e 100644
--- a/SourceCode/Bond/Servo/Servo.vcxproj.filters
+++ b/SourceCode/Bond/Servo/Servo.vcxproj.filters
@@ -197,6 +197,7 @@
<ClCompile Include="CServoUtilsTool.cpp" />
<ClCompile Include="GlassLogDb.cpp" />
<ClCompile Include="sqlite3.c" />
+ <ClCompile Include="CProcessDataListDlg.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="AlarmManager.h" />
@@ -419,6 +420,7 @@
<ClInclude Include="GlassLogDb.h" />
<ClInclude Include="sqlite3.h" />
<ClInclude Include="sqlite3ext.h" />
+ <ClInclude Include="CProcessDataListDlg.h" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="Servo.rc" />
diff --git a/SourceCode/Bond/Servo/resource.h b/SourceCode/Bond/Servo/resource.h
index 73f852c..bd3bb31 100644
--- a/SourceCode/Bond/Servo/resource.h
+++ b/SourceCode/Bond/Servo/resource.h
Binary files differ
diff --git a/SourceCode/Bond/x64/Debug/AlarmList.csv b/SourceCode/Bond/x64/Debug/AlarmList.csv
index 08cd213..61a6625 100644
--- a/SourceCode/Bond/x64/Debug/AlarmList.csv
+++ b/SourceCode/Bond/x64/Debug/AlarmList.csv
@@ -1,3 +1 @@
-锘縉o,UNIT ID,UNIT NO,Alarm Level,Alarm Code,AlarmID,Alarm Text,Description
-1,EFEM(ROBOT)-EFEM,,0,2,100,Fatal communication error in the ACLS receive loop. Please reboot MCC., Fatal communication error in the ACLS receive loop. Please reboot MCC.
-2,Load Port 1-EFEM,,1,1,101,"Must check substrate location due to the failure of ACLS operation <%s> ; To protect glass, a dummy glass has been created"," Must check substrate location due to the failure of ACLS operation <%s> ; To protect glass, a dummy glass has been created"
\ No newline at end of file
+No,UNIT ID,UNIT NO,Alarm Level,Alarm Code,AlarmID,Alarm Text,Description
1,EFEM,100,0,0,1000,机器人CCLink链接异常,"请检查接线,断电重启"
2,EFEM,101,0,0,1001,相机CCLink链接异常,"请检查接线,断电重启"
3,EFEM,102,0,0,1002,静电测试CCLink链接异常,"请检查接线,断电重启"
4,EFEM,103,0,0,1003,,
5,EFEM,104,0,0,1004,,
6,EFEM,105,0,0,1005,,
7,EFEM,106,0,0,1006,,
8,EFEM,107,0,0,1007,,
9,EFEM,108,0,0,1008,,
10,EFEM,109,0,0,1009,,
11,EFEM,110,0,0,1010,总进气气压异常,请检测进气
12,EFEM,111,0,0,1011,总真空气压异常,请检测真空
13,EFEM,112,0,0,1012,LP真空异常,检测真空
14,EFEM,113,0,0,1013,离子风棒压空异常,请检测进气
15,EFEM,114,0,0,1014,机器人真空异常,请检测真空
16,EFEM,115,0,0,1015,急停被按下,请检查急停按钮
17,EFEM,116,0,0,1016,,
18,EFEM,117,0,0,1017,,
19,EFEM,118,0,0,1018,,
20,EFEM,119,0,0,1019,,
21,EFEM,120,0,0,1020,安全门打开,请检查安全门
22,EFEM,121,0,0,1021,正面左门打开中,请检查安全门
23,EFEM,122,0,0,1022,正面右门打开中,请检查安全门
24,EFEM,123,0,0,1023,侧面左门打开中,请检查安全门
25,EFEM,124,0,0,1024,侧面右门打开中,请检查安全门
26,EFEM,125,0,0,1025,背面左门打开中,请检查安全门
27,EFEM,126,0,0,1026,背面右门打开中,请检查安全门
28,EFEM,127,0,0,1027,,
29,EFEM,128,0,0,1028,,
30,EFEM,129,0,0,1029,,
31,EFEM,130,0,0,1030,,
32,EFEM,131,0,0,1031,"Port1_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
33,EFEM,132,0,0,1032,"Port1_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
34,EFEM,133,0,0,1033,"Port1_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
35,EFEM,134,0,0,1034,,
36,EFEM,135,0,0,1035,,
37,EFEM,136,0,0,1036,,
38,EFEM,137,0,0,1037,,
39,EFEM,138,0,0,1038,,
40,EFEM,139,0,0,1039,,
41,EFEM,140,1,0,1040,"Port1_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
42,EFEM,141,1,0,1041,"Port1_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
43,EFEM,142,1,0,1042,"Port1_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
44,EFEM,143,1,0,1043,"Port1_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
45,EFEM,144,0,0,1044,,
46,EFEM,145,0,0,1045,,
47,EFEM,146,0,0,1046,,
48,EFEM,147,0,0,1047,,
49,EFEM,148,0,0,1048,,
50,EFEM,149,0,0,1049,,
51,EFEM,150,0,0,1050,"Port2_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
52,EFEM,151,0,0,1051,"Port2_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
53,EFEM,152,0,0,1052,"Port2_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
54,EFEM,153,0,0,1053,,
55,EFEM,154,0,0,1054,,
56,EFEM,155,0,0,1055,,
57,EFEM,156,0,0,1056,,
58,EFEM,157,0,0,1057,,
59,EFEM,158,0,0,1058,,
60,EFEM,159,0,0,1059,,
61,EFEM,160,0,0,1060,"Port2_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
62,EFEM,161,0,0,1061,"Port2_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
63,EFEM,162,0,0,1062,"Port2_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
64,EFEM,163,0,0,1063,"Port2_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
65,EFEM,164,0,0,1064,,
66,EFEM,165,0,0,1065,,
67,EFEM,166,0,0,1066,,
68,EFEM,167,0,0,1067,,
69,EFEM,168,0,0,1068,,
70,EFEM,169,0,0,1069,,
71,EFEM,170,1,0,1070,,
72,EFEM,171,1,0,1071,"Port3_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
73,EFEM,172,1,0,1072,"Port3_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
74,EFEM,173,1,0,1073,"Port3_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
75,EFEM,174,1,0,1074,"Port3_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
76,EFEM,175,1,0,1075,,
77,EFEM,176,1,0,1076,,
78,EFEM,177,1,0,1077,,
79,EFEM,178,1,0,1078,,
80,EFEM,179,1,0,1079,,
81,EFEM,180,1,0,1080,"Port3_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
82,EFEM,181,1,0,1081,"Port3_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
83,EFEM,182,1,0,1082,"Port3_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
84,EFEM,183,1,0,1083,,
85,EFEM,184,1,0,1084,,
86,EFEM,185,1,0,1085,,
87,EFEM,186,1,0,1086,,
88,EFEM,187,1,0,1087,,
89,EFEM,188,1,0,1088,,
90,EFEM,189,1,0,1089,,
91,EFEM,190,1,0,1090,,
92,EFEM,191,1,0,1091,"Port4_E84流程停止,OHT_VALID信号异常",请检查OHT信号或者E84线缆
93,EFEM,192,1,0,1092,"Port4_E84流程停止,光栅被遮挡或者急停被拍",请检查光栅信号急停
94,EFEM,193,1,0,1093,"Port4_E84流程停止,OHT_取或放FOUP超时","OHT_BUSY后未在规定时间内取走FOUP,请检查OHT或者核对LP状态"
95,EFEM,194,1,0,1094,"Port4_E84流程停止,OHT_BUSY_OFF或者TR_REQ_OFF信号超时",请检查OHT信号或者E84线缆
96,EFEM,195,1,0,1095,,
97,EFEM,196,1,0,1096,,
98,EFEM,197,1,0,1097,,
99,EFEM,198,1,0,1098,,
100,EFEM,199,1,0,1099,,
101,EFEM,200,1,0,1100,"Port4_E84流程异常,OHT_TR_REQ_ON信号超时",请检查OHT或者E84线缆
102,EFEM,201,1,0,1101,"Port4_E84流程异常,OHT_BUSY_ON信号超时",请检查OHT或者E84线缆
103,EFEM,202,1,0,1102,"Port4_E84流程异常,OHT_COMPT_OFF信号超时",请检查OHT信号或者E84线缆
104,EFEM,203,1,0,1103,,
105,EFEM,204,1,0,1104,,
106,EFEM,205,1,0,1105,,
107,EFEM,206,1,0,1106,,
108,EFEM,207,1,0,1107,,
109,EFEM,208,1,0,1108,,
110,EFEM,209,1,0,1109,,
111,EFEM,210,0,0,1110,回原点失败/超时,请检查设备状态以及轴位置是否有干涉,请重新执行回原操作
112,EFEM,211,0,0,1111,Flip工位,真空打开时在荷异常,请检查玻璃位置
113,EFEM,212,1,0,1112,,
114,EFEM,213,1,0,1113,,
115,EFEM,214,1,0,1114,,
116,EFEM,215,1,0,1115,,
117,EFEM,216,1,0,1116,,
118,EFEM,217,1,0,1117,,
119,EFEM,218,1,0,1118,,
120,EFEM,219,1,0,1119,,
121,EFEM,220,1,0,1120,任务取消失败,当前取消任务条件不满足
122,EFEM,221,1,0,1121,任务重试失败,当前重试任务条件不满足
\ No newline at end of file
--
Gitblit v1.9.3