예제 #1
0
파일: CDio.cs 프로젝트: zoro-008/Works
 public void Update()
 {
     for (int i = 0; i < m_iModuleCnt; i++)
     {
         if (m_aModuleInfo[i].iCntIn == 32 || m_aModuleInfo[i].iCntOut == 32)
         {
             CAXD.AxdoWriteOutportDword(i, 0, m_aModuleInfo[i].uDataOutSet);
             CAXD.AxdoReadOutportDword(i, 0, ref m_aModuleInfo[i].uDataOutGet);
             CAXD.AxdiReadInportDword(i, 0, ref m_aModuleInfo[i].uDataIn);
         }
         else if (m_aModuleInfo[i].iCntIn == 16 || m_aModuleInfo[i].iCntOut == 16)
         {
             CAXD.AxdoWriteOutportWord(i, 0, m_aModuleInfo[i].uDataOutSet);
             CAXD.AxdoReadOutportWord(i, 0, ref m_aModuleInfo[i].uDataOutGet);
             CAXD.AxdiReadInportWord(i, 0, ref m_aModuleInfo[i].uDataIn);
         }
         //m_aModuleInfo[i].uDataOutSet = 0;// m_aModuleInfo[i].uDataOutGet;
     }
 }