Esempio n. 1
0
 /// <summary>
 /// 读取CAN状态
 /// </summary>
 /// <param name="pCanStatus"></param>
 /// <returns></returns>
 public uint ReadCanStatus(ref CAN_STATUS pCanStatus)
 {
     if (CANDLL.ReadCanStatus((UInt32)p_ParentDevice.DeviceType, p_ParentDevice.DeviceIndex, m_ChannelIndex, ref pCanStatus) == CAN.CAN_DLL_RESULT_SUCCESS)
     {
         Logger.Info(string.Format("channel[{0}] read can status successful.", m_ChannelName));
         return((uint)CAN_RESULT.SUCCESSFUL);
     }
     Logger.Info(string.Format("channel[{0}] read can status failed.", m_ChannelName));
     return((uint)CAN_RESULT.ERR_UNKNOWN);
 }
Esempio n. 2
0
 public static extern UInt32 ReadCanStatus(UInt32 DeviceType, UInt32 DeviceIndex, UInt32 CANIndex, ref CAN_STATUS pCANStatus);