AbstractAcq.h 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. #ifndef ABSTRACTACQ_EXPORTS
  2. #ifdef WIN_64BIT
  3. #ifdef _DEBUG
  4. #pragma comment(lib, "AbstractAcqX64D.lib")
  5. #else
  6. #pragma comment(lib, "AbstractAcqX64.lib")
  7. #endif
  8. #else
  9. #ifdef _DEBUG
  10. #pragma comment(lib, "AbstractAcqD.lib")
  11. #else
  12. #pragma comment(lib, "AbstractAcq.lib")
  13. #endif
  14. #endif
  15. #endif
  16. #ifdef ABSTRACTACQ_EXPORTS
  17. #define ABSTRACTACQ_API __declspec(dllexport)
  18. #else
  19. #define ABSTRACTACQ_API __declspec(dllimport)
  20. #endif
  21. #include "LogicDevice.h"
  22. #include "CommonLogicClient.h"
  23. #include <map>
  24. class ABSTRACTACQ_API AbstractAcq : public LogicDevice
  25. {
  26. public:
  27. AbstractAcq(void);
  28. virtual ~AbstractAcq(void);
  29. void *m_pData;
  30. char *m_chLog;
  31. //get device type
  32. virtual bool SYSTEM_CALL GetDeviceType(GUID &DevType);
  33. //get device resource
  34. virtual RET_STATUS SYSTEM_CALL GetDeviceResource(ResDataObject PARAM_OUT *pDeviceResource);
  35. //ResourceCommand Request In and Response Out
  36. virtual RET_STATUS SYSTEM_CALL Request(ResDataObject PARAM_IN *pRequest, ResDataObject PARAM_OUT *pResponse);
  37. //notify to lower layer
  38. virtual RET_STATUS SYSTEM_CALL CmdToLogicDev(ResDataObject PARAM_IN *pCmd);
  39. //errors,warnings
  40. void SetErrorInfo(int errCode, char *pErrInfo);
  41. void SetWarningInfo(int warningCode, char *pWarningInfo);
  42. void LogInfo(string str);
  43. public:
  44. void InitState(map<CommonLogicClient*, int> &objSM);
  45. bool StateAction(char*, map<CommonLogicClient*, int>& objSM);
  46. bool StateGuard(char*, map<CommonLogicClient*, int> &objSM);
  47. bool StateNotify(char* strState, bool bResult);
  48. public:
  49. //fpd actions
  50. virtual RET_STATUS OpenLogicDevice();
  51. virtual RET_STATUS CloseLogicDevice();
  52. virtual RET_STATUS AddLogicDevice(string path);
  53. virtual RET_STATUS DelLogicDevice(string path);
  54. virtual RET_STATUS SetApplicationMode(ResDataObject nApplicationMode);
  55. virtual RET_STATUS SetExamMode(ResDataObject nExamMode);
  56. virtual RET_STATUS SetImgID(ResDataObject nImgID);
  57. virtual RET_STATUS GetSEQResource(ResDataObject PARAM_OUT *pDeviceResource);
  58. virtual RET_STATUS SeqPrep();
  59. virtual RET_STATUS SeqReady();
  60. virtual RET_STATUS FramePrep();
  61. virtual RET_STATUS FrameReady();
  62. virtual RET_STATUS FrameStart();
  63. virtual RET_STATUS XWindowOn();
  64. virtual RET_STATUS FrameIn();
  65. virtual RET_STATUS FrameInComplete();
  66. virtual RET_STATUS FramePost();
  67. virtual RET_STATUS FramePostResult();
  68. virtual RET_STATUS FrameEnd();
  69. virtual RET_STATUS FrameEndResult();
  70. virtual RET_STATUS SeqPost();
  71. virtual RET_STATUS SeqPostResult();
  72. //we need check each action resource is Support or not
  73. //return yes or no inside of OEM module
  74. virtual RET_STATUS Support_SetSyncMode();
  75. virtual RET_STATUS Support_SetXWindowTime();
  76. virtual RET_STATUS Support_SetApplicationMode();
  77. virtual RET_STATUS Support_SetExamMode();
  78. virtual RET_STATUS Support_GetSEQResource();
  79. virtual RET_STATUS Support_SeqPrep();
  80. virtual RET_STATUS Support_SeqReady();
  81. virtual RET_STATUS Support_FramePrep();
  82. virtual RET_STATUS Support_FrameReady();
  83. virtual RET_STATUS Support_FrameStart();
  84. virtual RET_STATUS Support_XWindowOn();
  85. virtual RET_STATUS Support_FrameIn();
  86. virtual RET_STATUS Support_FrameInComplete();
  87. virtual RET_STATUS Support_FramePost();
  88. virtual RET_STATUS Support_FramePostResult();
  89. virtual RET_STATUS Support_FrameEnd();
  90. virtual RET_STATUS Support_FrameEndResult();
  91. virtual RET_STATUS Support_SeqPost();
  92. virtual RET_STATUS Support_SeqPostResult();
  93. };