From 7203ac92219156addaa0d4b6e6a9d81b5ffe8a13 Mon Sep 17 00:00:00 2001
From: Darker <mr.darker@163.com>
Date: 星期三, 26 二月 2025 09:56:59 +0800
Subject: [PATCH] 1. 添加报警对话框的按钮 2. 接受报警消息,并获取数据添加到数据库和显示在界面列表

---
 SourceCode/Bond/Servo/Model.cpp |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/SourceCode/Bond/Servo/Model.cpp b/SourceCode/Bond/Servo/Model.cpp
index 66cf9a7..38ad39f 100644
--- a/SourceCode/Bond/Servo/Model.cpp
+++ b/SourceCode/Bond/Servo/Model.cpp
@@ -99,8 +99,18 @@
 	masterListener.onEqCimStateChanged = [&](void* pMaster, SERVO::CEquipment* pEquipment, BOOL bOn) -> void {
 		LOGI("<CModel>Equipment Cim State:%s(%s).\n", pEquipment->getName().c_str(),
 			bOn ? _T("ON") : _T("OFF"));
+		notifyPtr(RX_CODE_EQ_ALIVE, pEquipment);
 
 	};
+	masterListener.onEqStepEvent = [&](SERVO::CStep* pStep, int code, void* pData) -> void {
+		if (code == STEP_EVENT_READDATA) {
+			LOGI("<CModel>onEqStepEvent,数据变化:%s(%s, 0x%x).\n", pStep->getEquipment()->getName().c_str(),
+				pStep->getName().c_str(), pData);
+			notifyPtr(RX_CODE_STEP_EVENT_READDATA, pStep);
+			
+		}
+	};
+
 	m_master.setListener(masterListener);
 
 	return 0;

--
Gitblit v1.9.3