DIOS.Dev.MechanicalMoudle.hpp 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. #pragma once
  2. #include <string>
  3. #include <minwindef.h>
  4. #include "ResDataObject.h"
  5. #include "DIOS.Dev.IODevice.hpp"
  6. #include "DIOS.Dev.IODevice.Detail.hpp"
  7. namespace DIOS::Dev::Detail::MECH
  8. {
  9. //-----------------------------------------------------------------------------
  10. // Collimator
  11. //-----------------------------------------------------------------------------
  12. namespace nsDev = DIOS::Dev;
  13. static const char* MechanicalUnitType = "{A6C288B9-8C4F-3A6C-9C5F-12345A0F7284}";
  14. class MechanicalDevice : public IODeviceDetail
  15. {
  16. using super = IODeviceDetail;
  17. void FireNotify(string key, unsigned int value);
  18. void FireNotify(string key, float value);
  19. void FireNotify(string key, string value);
  20. protected:
  21. std::shared_ptr <DIOS::Dev::IOEventCenter> m_EventCenter;
  22. unsigned int m_Grid;
  23. unsigned int m_Mammo_AE;
  24. unsigned int m_Mammo_FT;
  25. unsigned int m_Mammo_PressureState;
  26. unsigned int m_Mammo_CompPressureDEC;
  27. unsigned int m_Mammo_Depress;
  28. float m_Mammo_MechAngle;
  29. float m_Mammo_MechHeight;
  30. float m_Mammo_PressureValue;
  31. float m_Mammo_AGD;
  32. float m_Mammo_MAG;
  33. string m_Mammo_CompressPaddle; //压迫板信息(主要是尺寸,目前不确定)
  34. public:
  35. MechanicalDevice(std::shared_ptr <DIOS::Dev::IOEventCenter> EventCenter);
  36. ~MechanicalDevice();
  37. virtual std::string GetGUID() const override;
  38. virtual bool Prepare();
  39. virtual void Register();
  40. nsDev::RET_STATUS JSSetGrid(std::string in, std::string& out);
  41. nsDev::RET_STATUS JSSetAutoTracking(std::string in, std::string& out);
  42. nsDev::RET_STATUS JSGetTomoResults(std::string in, std::string& out);
  43. nsDev::RET_STATUS JSGetGrid(std::string& out);
  44. nsDev::RET_STATUS JSGetMammo_AE(std::string& out);
  45. nsDev::RET_STATUS JSGetMammo_FT(std::string& out);
  46. nsDev::RET_STATUS JSGetMammo_PressureState(std::string& out);
  47. nsDev::RET_STATUS JSGetMammo_CompPressureDEC(std::string& out);
  48. nsDev::RET_STATUS JSGetMammo_Depress(std::string& out);
  49. nsDev::RET_STATUS JSGetMammo_MechAngle(std::string& out);
  50. nsDev::RET_STATUS JSGetMammo_MechHeight(std::string& out);
  51. nsDev::RET_STATUS JSGetMammo_PressureValue(std::string& out);
  52. nsDev::RET_STATUS JSGetMammo_AGD(std::string& out);
  53. nsDev::RET_STATUS JSGetMammo_MAG(std::string& out);
  54. nsDev::RET_STATUS JSGetMammo_CompressPaddle(std::string& out);
  55. virtual RET_STATUS GetTomoResults(ResDataObject& resultAngle, ResDataObject& resultHeight);
  56. virtual RET_STATUS SetGrid(unsigned int GridType);
  57. virtual RET_STATUS SetAutoTracking(unsigned int nAutoTracking);
  58. void UpdateGrid(unsigned int Value);
  59. void UpdateMammo_AE(unsigned int Value);
  60. void UpdateMammo_FT(unsigned int Value);
  61. void UpdateMammo_PressureState(unsigned int Value);
  62. void UpdateMammo_CompPressureDEC(unsigned int Value);
  63. void UpdateMammo_Depress(unsigned int Value);
  64. void UpdateMammo_MechAngle(float Value);
  65. void UpdateMammo_MechHeight(float Value);
  66. void UpdateMammo_PressureValue(float Value);
  67. void UpdateMammo_AGD(float Value);
  68. void UpdateMammo_MAG(float Value);
  69. void UpdateMammo_CompressPaddle(std::string Value);
  70. };
  71. }