From 9e25e06d7ec9d7cd1c31a9d30a8a018e2af63e3a Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期五, 29 八月 2025 11:28:16 +0800
Subject: [PATCH] 1.Port Unload Ready,事件的上报,EAP模拟程序观察验证数据;
---
SourceCode/Bond/Servo/CEquipment.cpp | 65 +++++++++++++++++++++++++++++---
1 files changed, 59 insertions(+), 6 deletions(-)
diff --git a/SourceCode/Bond/Servo/CEquipment.cpp b/SourceCode/Bond/Servo/CEquipment.cpp
index 26b20d3..8d8582d 100644
--- a/SourceCode/Bond/Servo/CEquipment.cpp
+++ b/SourceCode/Bond/Servo/CEquipment.cpp
@@ -27,6 +27,7 @@
m_pArm = nullptr;
m_processState = PROCESS_STATE::Ready;
m_blockReadBit = { 0 };
+ m_nTestFlag = 0;
InitializeCriticalSection(&m_criticalSection);
}
@@ -525,8 +526,12 @@
// EQ Job Event
CHECK_READ_STEP_SIGNAL(STEP_ID_RECIVE_JOB_UPS1, pszData, size);
CHECK_READ_STEP_SIGNAL(STEP_ID_RECIVE_JOB_UPS2, pszData, size);
+ CHECK_READ_STEP_SIGNAL(STEP_ID_RECIVE_JOB_UPS3, pszData, size);
+ CHECK_READ_STEP_SIGNAL(STEP_ID_RECIVE_JOB_UPS4, pszData, size);
CHECK_READ_STEP_SIGNAL(STEP_ID_SENT_OUT_JOB_DOWNS1, pszData, size);
CHECK_READ_STEP_SIGNAL(STEP_ID_SENT_OUT_JOB_DOWNS2, pszData, size);
+ CHECK_READ_STEP_SIGNAL(STEP_ID_SENT_OUT_JOB_DOWNS3, pszData, size);
+ CHECK_READ_STEP_SIGNAL(STEP_ID_SENT_OUT_JOB_DOWNS4, pszData, size);
// Store Job Report #1~15
CHECK_READ_STEP_SIGNAL(STEP_ID_STORE_JOB_REPORT1, pszData, size);
@@ -1270,6 +1275,12 @@
if (m_slot[i].isLock()) continue;
if (!m_slot[i].isEmpty()) continue;
+ int lsPath = m_slot[i].getLinkSignalPath();
+ if (!m_bLinkSignalToDownstream[lsPath][SIGNAL_UPSTREAM_INLINE]
+ || m_bLinkSignalToDownstream[lsPath][SIGNAL_UPSTREAM_TROUBLE]
+ || !m_bLinkSignalToDownstream[lsPath][SIGNAL_INTERLOCK]
+ || !m_bLinkSignalToDownstream[lsPath][SIGNAL_RECEIVE_ABLE]) continue;
+
MaterialsType slotType = m_slot[i].getType();
if (type == MaterialsType::G1 && slotType == MaterialsType::G2) continue;
if (type == MaterialsType::G2 && slotType == MaterialsType::G1) continue;
@@ -1280,6 +1291,21 @@
}
return nullptr;
+ }
+
+ CSlot* CEquipment::isSlotAvailable(unsigned int slot)
+ {
+ if (slot >= 8) return nullptr;
+ if (!m_slot[slot].isEnable()) return nullptr;
+ if (m_slot[slot].isLock()) return nullptr;
+ if (!m_slot[slot].isEmpty()) return nullptr;
+ int lsPath = m_slot[slot].getLinkSignalPath();
+ if (!m_bLinkSignalToDownstream[lsPath][SIGNAL_UPSTREAM_INLINE]
+ || m_bLinkSignalToDownstream[lsPath][SIGNAL_UPSTREAM_TROUBLE]
+ || !m_bLinkSignalToDownstream[lsPath][SIGNAL_INTERLOCK]
+ || !m_bLinkSignalToDownstream[lsPath][SIGNAL_RECEIVE_ABLE]) return nullptr;
+
+ return &m_slot[slot];
}
CSlot* CEquipment::getNonEmptySlot(MaterialsType putSlotType)
@@ -1300,25 +1326,35 @@
return nullptr;
}
- CSlot* CEquipment::getProcessedSlot(MaterialsType putSlotType)
+ CSlot* CEquipment::getProcessedSlot(MaterialsType putSlotType, BOOL bJobMode/* = FALSE*/)
{
for (int i = 0; i < SLOT_MAX; i++) {
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 001");
if (!m_slot[i].isEnable()) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 002");
if (m_slot[i].isLock()) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 003");
CGlass* pGlass = (CGlass*)m_slot[i].getContext();
if (!isSlotProcessed(i)) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 004");
if (pGlass == nullptr) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 005");
+ if (!pGlass->isScheduledForProcessing()) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 006");
+ if (bJobMode && pGlass->getProcessJob() == nullptr) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 007");
if(pGlass->getInspResult(m_nID, 0) == InspResult::Fail) continue;
int lsPath = m_slot[i].getLinkSignalPath();
if(!m_bLinkSignalToUpstream[lsPath][SIGNAL_UPSTREAM_INLINE]
|| m_bLinkSignalToUpstream[lsPath][SIGNAL_UPSTREAM_TROUBLE]
|| !m_bLinkSignalToUpstream[lsPath][SIGNAL_INTERLOCK]
|| !m_bLinkSignalToUpstream[lsPath][SIGNAL_SEND_ABLE] ) continue;
-
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 008");
MaterialsType glassType = pGlass->getType();
if (glassType == MaterialsType::G1 && putSlotType == MaterialsType::G2) continue;
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 009");
if (glassType == MaterialsType::G2 && putSlotType == MaterialsType::G1) continue;
-
+ if (m_nTestFlag == 1) LOGI("getProcessedSlot 00a");
return &m_slot[i];
}
@@ -1353,6 +1389,22 @@
return nullptr;
}
+ CSlot* CEquipment::getProcessedSlotCt(unsigned int slot)
+ {
+ if (slot >= 8) return nullptr;
+ if (!m_slot[slot].isEnable()) return nullptr;
+ if (m_slot[slot].isLock()) return nullptr;
+ CGlass* pGlass = (CGlass*)m_slot[slot].getContext();
+ if (pGlass == nullptr) return nullptr;
+ int lsPath = m_slot[slot].getLinkSignalPath();
+ if (!m_bLinkSignalToUpstream[lsPath][SIGNAL_UPSTREAM_INLINE]
+ || m_bLinkSignalToUpstream[lsPath][SIGNAL_UPSTREAM_TROUBLE]
+ || !m_bLinkSignalToUpstream[lsPath][SIGNAL_INTERLOCK]
+ || !m_bLinkSignalToUpstream[lsPath][SIGNAL_SEND_ABLE]) return nullptr;
+
+ return &m_slot[slot];
+ }
+
CSlot* CEquipment::getInspFailSlot()
{
for (int i = 0; i < SLOT_MAX; i++) {
@@ -1360,6 +1412,7 @@
if (m_slot[i].isLock()) continue;
CGlass* pGlass = (CGlass*)m_slot[i].getContext();
if (pGlass == nullptr) continue;
+ if (!pGlass->isScheduledForProcessing()) continue;
if (pGlass->getInspResult(m_nID, 0) != InspResult::Fail) continue;
int lsPath = m_slot[i].getLinkSignalPath();
if (!m_bLinkSignalToUpstream[lsPath][SIGNAL_UPSTREAM_INLINE]
@@ -1611,7 +1664,7 @@
int CEquipment::decodeVCREventReport(CStep* pStep, const char* pszData, size_t size)
{
CVcrEventReport vcrEventReport;
- vcrEventReport.unserialize(pszData, size);
+ vcrEventReport.unserialize(pszData, (int)size);
LOGI("<CEquipment-%s>decodeVCREventReport<Result:%d, GlassId:%s>\n", m_strName.c_str(),
vcrEventReport.getVcrResult(),
vcrEventReport.getGlassId().c_str());
@@ -1947,14 +2000,14 @@
*/
int CEquipment::onSendAble(int port)
{
- LOGI("<CEquipment-%s>onSendAble.port:%d", m_strName.c_str(), port);
+ // LOGI("<CEquipment-%s>onSendAble.port:%d", m_strName.c_str(), port);
return 0;
}
int CEquipment::onReceiveAble(int port)
{
- LOGI("<CEquipment-%s>onReceiveAble.port:%d", m_strName.c_str(), port);
+ // LOGI("<CEquipment-%s>onReceiveAble.port:%d", m_strName.c_str(), port);
return 0;
}
--
Gitblit v1.9.3