From e1b3a1f5e35b09be95d694bc259b0ba92c4d3436 Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期六, 26 四月 2025 10:55:23 +0800
Subject: [PATCH] 1.再一次修改地址;
---
SourceCode/Bond/Servo/CLoadPort.cpp | 76 ++++++++++++++++++++++++++++++++++++++
1 files changed, 76 insertions(+), 0 deletions(-)
diff --git a/SourceCode/Bond/Servo/CLoadPort.cpp b/SourceCode/Bond/Servo/CLoadPort.cpp
index bda1be4..3e93d7c 100644
--- a/SourceCode/Bond/Servo/CLoadPort.cpp
+++ b/SourceCode/Bond/Servo/CLoadPort.cpp
@@ -34,6 +34,9 @@
{
// 加入Pin初始化代码
LOGI("<CLoadPort>initPins");
+ addPin(SERVO::PinType::INPUT, _T("In"));
+ addPin(SERVO::PinType::OUTPUT, _T("Out1"));
+ addPin(SERVO::PinType::OUTPUT, _T("Out2"));
}
void CLoadPort::onTimer(UINT nTimerid)
@@ -45,4 +48,77 @@
{
CEquipment::serialize(ar);
}
+
+ void CLoadPort::getAttributeVector(CAttributeVector& attrubutes)
+ {
+ __super::getAttributeVector(attrubutes);
+ }
+
+ int CLoadPort::recvIntent(CPin* pPin, CIntent* pIntent)
+ {
+ return __super::recvIntent(pPin, pIntent);
+ }
+
+ int CLoadPort::outputGlass(int port)
+ {
+ // 如果列表中没有Panel,模拟生成10张
+ if (m_glassList.empty()) {
+ static int ii = 0;
+ char szBuffer[64];
+ LOGI("<CLoadPort>模拟生成10张PANEL");
+ for (int i = 0; i < 10; i++) {
+ sprintf_s(szBuffer, "P20250320A1A%d", ++ii);
+ CGlass* pGlass = new CGlass();
+ pGlass->setID(szBuffer);
+ addGlassToList(pGlass);
+ }
+ }
+
+ return __super::outputGlass(port);
+ }
+
+ BOOL CLoadPort::glassWillArrive(CGlass* pGlass)
+ {
+ BOOL bRet = __super::glassWillArrive(pGlass);
+ if (!bRet) {
+ return FALSE;
+ }
+
+ return (m_glassList.size() < 8);
+ }
+
+ int CLoadPort::sendCassetteCtrlCmd(short cmd,
+ short* jobExistence,
+ int jobExistenceSize,
+ short slotProcess,
+ short jopCount,
+ CJobDataA* pJobDataA)
+ {
+ int id = getID();
+ if ( !(id == EQ_ID_LOADPORT1 || id == EQ_ID_LOADPORT2) ) {
+ return -1;
+ }
+
+
+ SERVO::CEqCassetteCtrlCmdStep* pStep = (SERVO::CEqCassetteCtrlCmdStep*)getCassetteCtrlCmdStep();
+ ASSERT(pStep);
+ return pStep->sendCtrlCmd(cmd, jobExistence, jobExistenceSize, slotProcess, jopCount, pJobDataA);
+ }
+
+ CStep* CLoadPort::getCassetteCtrlCmdStep()
+ {
+ CStep* pStep = nullptr;
+ Lock();
+ for (auto item : m_mapStep) {
+ if (item.second->getName().find(STEP_EQ_P1_CASSETTE_CTRL_CMD) == 0
+ || item.second->getName().find(STEP_EQ_P2_CASSETTE_CTRL_CMD) == 0
+ || item.second->getName().find(STEP_EQ_P3_CASSETTE_CTRL_CMD) == 0
+ || item.second->getName().find(STEP_EQ_P4_CASSETTE_CTRL_CMD) == 0) {
+ pStep = item.second;
+ }
+ }
+ Unlock();
+
+ return pStep;
+ }
}
--
Gitblit v1.9.3