From d64036c0510cf06009a7252e318d828fbc2658f0 Mon Sep 17 00:00:00 2001
From: mrDarker <mr.darker@163.com>
Date: 星期四, 11 九月 2025 09:22:02 +0800
Subject: [PATCH] Merge branch 'clh' into liuyang

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

diff --git a/SourceCode/Bond/Servo/CMeasurement.cpp b/SourceCode/Bond/Servo/CMeasurement.cpp
index 0acf5ee..8357d01 100644
--- a/SourceCode/Bond/Servo/CMeasurement.cpp
+++ b/SourceCode/Bond/Servo/CMeasurement.cpp
@@ -334,6 +334,26 @@
 			}
 		}
 
+		// FAC Data Report
+		addFacDataReportStep(0x1a589, 0xf4d, 1);
+		/*
+		{
+			CEqReadStep* pStep = new CEqReadStep(0x1a589, 133 * 2,
+				[&](void* pFrom, int code, const char* pszData, size_t size) -> int {
+					if (code == ROK && pszData != nullptr && size > 0) {
+						decodeFacDataReport((CStep*)pFrom, pszData, size);
+					}
+					return -1;
+				});
+			pStep->setName(STEP_EQ_FAC_DATA_REPORT);
+			pStep->setProp("Port", (void*)1);
+			pStep->setWriteSignalDev(0xf4d);
+			if (addStep(STEP_ID_FAC_DATA_REPORT, pStep) != 0) {
+				delete pStep;
+			}
+		}
+		*/
+
 		// process start/end report
 		{
 			CEqReadStep* pStep = new CEqReadStep(0x19D3F, 13 * 2,
@@ -437,4 +457,35 @@
 
 		return (int)params.size();
 	}
+
+	int CMeasurement::parsingProcessData(const char* pszData, size_t size, std::vector<CParam>& params)
+	{
+		return parsingParams(pszData, size, params);
+	}
+
+	int CMeasurement::parsingSVData(const char* pszData, size_t size, std::vector<CParam>& params)
+	{
+		/*/
+		1	工艺运行步骤	1Word	123456
+			2	AOI检测速度	2Word	123.456
+		*/
+
+		ASSERT(pszData);
+		if (size < 125) return 0;
+		int i = 0, v;
+
+
+		// 1.工艺运行步骤
+		v = (pszData[i] & 0xff) | (pszData[i + 1] & 0xff) << 8;
+		params.push_back(CParam("工艺运行步骤", "", this->getName().c_str(), v));
+		i += 2;
+
+		// 2.检测速度
+		v = (pszData[i] & 0xff) | (pszData[i + 1] & 0xff) << 8 | (pszData[i + 2] & 0xff) << 16 | (pszData[i + 3] & 0xff) << 24;
+		params.push_back(CParam("A腔温控表1当前值", "", this->getName().c_str(), v * 0.001f));
+		i += 4;
+
+		return (int)params.size();
+	}
+
 }

--
Gitblit v1.9.3