LAPTOP-SNT8I5JK\Boounion
2025-05-12 9fbd7479ce17f76f72cc0e5a675336261ec76472
SourceCode/Bond/Servo/CEquipment.cpp
@@ -822,7 +822,7 @@
      return pGlass;
   }
   int CEquipment::fetchedOut(const char* pszGlassId)
   int CEquipment::fetchedOutJob(const char* pszGlassId)
   {
      if (m_pArm == nullptr) {
         return -1;
@@ -1061,6 +1061,56 @@
      return m_recipesManager.decodeRecipeParameterReport(pszData, size);
   }
   int CEquipment::decodeReceivedJobReport(CStep* pStep, int port, const char* pszData, size_t size)
   {
      CJobDataS jobDataS;
      int nRet = jobDataS.unserialize(&pszData[0], (int)size);
      if (nRet < 0) return nRet;
      // 缓存Attribute,用于调试时显示信息
      unsigned int weight = 201;
      CAttributeVector attrubutes;
      jobDataS.getAttributeVector(attrubutes, weight);
      pStep->addAttributeVector(attrubutes);
      onReceivedJob(port, &jobDataS);
      return nRet;
   }
   int CEquipment::onReceivedJob(int port, CJobDataS* pJobDataS)
   {
      LOGI("<CEquipment-%s>onReceivedJob.", m_strName.c_str());
      // return fetchedOutJob(pszGlassId);
      return 0;
   }
   int CEquipment::decodeSentOutJobReport(CStep* pStep, int port, const char* pszData, size_t size)
   {
      CJobDataS jobDataS;
      int nRet = jobDataS.unserialize(&pszData[0], (int)size);
      if (nRet < 0) return nRet;
      // 缓存Attribute,用于调试时显示信息
      unsigned int weight = 201;
      CAttributeVector attrubutes;
      jobDataS.getAttributeVector(attrubutes, weight);
      pStep->addAttributeVector(attrubutes);
      onReceivedJob(port, &jobDataS);
      return nRet;
   }
   int CEquipment::onSentOutJob(int port, CJobDataS* pJobDataS)
   {
      LOGI("<CEquipment-%s>onSentOutJob.", m_strName.c_str());
      // return fetchedOutJob(pszGlassId);
      return 0;
   }
   int CEquipment::decodeFetchedOutJobReport(CStep* pStep, int port, const char* pszData, size_t size)
   {
      int index = 0;
@@ -1098,16 +1148,16 @@
         jobDataB.getGlassId().c_str(), "", weight++));
      onFetchedOut(port, jobDataB.getGlassId().c_str());
      onFetchedOutJob(port, jobDataB.getGlassId().c_str());
      return index;
   }
   int CEquipment::onFetchedOut(int port, const char* pszGlassId)
   int CEquipment::onFetchedOutJob(int port, const char* pszGlassId)
   {
      LOGI("<CEquipment-%s>onFetchedOut:port:%d|GlassId:%s",
      LOGI("<CEquipment-%s>onFetchedOutJob:port:%d|GlassId:%s",
         m_strName.c_str(), port, pszGlassId);
      return fetchedOut(pszGlassId);
      return fetchedOutJob(pszGlassId);
   }
   int CEquipment::decodeStoredJobReport(CStep* pStep, int port, const char* pszData, size_t size)
@@ -1147,12 +1197,12 @@
         jobDataB.getGlassId().c_str(), "", weight++));
      onStore(port, jobDataB.getGlassId().c_str());
      onStoreJob(port, jobDataB.getGlassId().c_str());
      return index;
   }
   int CEquipment::onStore(int port, const char* pszGlassId)
   int CEquipment::onStoreJob(int port, const char* pszGlassId)
   {
      LOGI("<CEquipment-%s>onStore:port:%d|GlassId:%s",
         m_strName.c_str(), port, pszGlassId);