#pragma once #include "types.h" #include "PCANBasic.h" class CCanSensor { public: TPCANStatus Initialize(); TPCANStatus Uninitialize(); TPCANStatus Read(TPCANMsg* MessageBuffer, TPCANTimestamp* TimestampBuffer); TPCANStatus Write(TPCANMsg* MessageBuffer); TPCANStatus GetErrorText(TPCANStatus Error, WORD Language, LPSTR Buffer); private: //TPCANStatus InitCan(TPCANBaudrate Btr0Btr1, TPCANType HwType = 0, DWORD IOPort = 0, WORD Interrupt = 0); private: TPCANHandle _handle=PCAN_NONEBUS; bool _isFD; };