DialogADCalibrationMain.h 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. #pragma once
  2. #include "afxwin.h"
  3. // CDialogADCalibrationMain 对话框
  4. class CDialogADCalibrationMain : public CDialogEx
  5. {
  6. DECLARE_DYNAMIC(CDialogADCalibrationMain)
  7. public:
  8. CDialogADCalibrationMain(CWnd* pParent = NULL); // 标准构造函数
  9. virtual ~CDialogADCalibrationMain();
  10. // 对话框数据
  11. enum { IDD = IDD_DIALOG_AD_CAL_MAIN };
  12. protected:
  13. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
  14. DECLARE_MESSAGE_MAP()
  15. public:
  16. afx_msg void OnBnClickedButtonRotateTubeAngle();
  17. afx_msg void OnBnClickedButtonMoveTubeHeight();
  18. afx_msg void OnBnClickedButtonReadAdTubeAngle();
  19. afx_msg void OnBnClickedButtonReadAdTubeHeight();
  20. afx_msg void OnBnClickedButtonReadAdDetHeight();
  21. afx_msg void OnBnClickedButtonCalTubeAngleAd();
  22. afx_msg void OnBnClickedButtonCalTubeHeightAd();
  23. afx_msg void OnBnClickedButtonCalDetHeightAd();
  24. afx_msg void OnBnClickedButtonReadEncoderTubeAngle();
  25. afx_msg void OnBnClickedButtonReadEncoderTubeHeight();
  26. afx_msg void OnBnClickedButtonEnterCalibration();
  27. afx_msg void OnBnClickedButtonExitCalibration();
  28. afx_msg void OnBnClickedButtonResetSystem();
  29. afx_msg void OnBnClickedButtonCenteradjust();
  30. afx_msg void OnBnClickedButtonParking();
  31. afx_msg void OnBnClickedButtonTubeAngleLowLimit();
  32. afx_msg void OnBnClickedButtonTubeHeightLowLimit();
  33. afx_msg void OnBnClickedButtonEnterSelftest();
  34. afx_msg void OnBnClickedButtonExitSelftest();
  35. afx_msg void OnBnClickedButtonStartSelftest();
  36. afx_msg void OnBnClickedButtonActiveTubeAngleZClear();
  37. afx_msg void OnBnClickedButtonCancelTubeAngleZClear();
  38. afx_msg void OnBnClickedButtonActiveTubeHeightZClear();
  39. afx_msg void OnBnClickedButtonCancelTubeHeightZClear();
  40. afx_msg void OnBnClickedButtonRotateToTubeAngleZAxis();
  41. afx_msg void OnBnClickedButtonMoveToTubeHeightZAxis();
  42. afx_msg void OnBnClickedButtonEmStop();
  43. afx_msg void OnBnClickedButtonSetPcodeParam();
  44. afx_msg void OnBnClickedButtonRotateTubeAnglePhy();
  45. afx_msg void OnBnClickedButtonMoveTubeHeightPhy();
  46. private:
  47. void SetExamMode(int mode);
  48. private:
  49. // 球管旋转角度
  50. CComboBox m_rotateDirection;
  51. // 球管旋转步长
  52. CEdit m_rotateStep;
  53. // 球管高度移动方向
  54. CComboBox m_tubeHeightDirection;
  55. // 球管高度移动步长
  56. CEdit m_tubeHeightStep;
  57. // 球管角度AD值
  58. CEdit m_tubeAngleAD;
  59. // 球管角度校正AD数组
  60. CEdit m_tubeAngleCalADs;
  61. // 球管角度校正物理值数组
  62. CEdit m_tubeAngleCalPhysicals;
  63. // 球管高度AD
  64. CEdit m_tubeHeightAD;
  65. // 球管高度校正AD数组
  66. CEdit m_tubHeightCalADs;
  67. // 球管高度校正物理数组
  68. CEdit m_tubeHeightCalPhysicals;
  69. // 探测器高度AD
  70. CEdit m_detectorAD;
  71. // 探测器高度校正AD数组
  72. CEdit m_detectorCalAds;
  73. // 探测器高度校正物理值数组
  74. CEdit m_detectorHeightCalPhysicals;
  75. // 球管角度编码器读数
  76. CEdit m_tubeAngleEncoder;
  77. // 球管高度编码器读数
  78. CEdit m_tubeHeightEncoder;
  79. // PositionCode
  80. CEdit m_pcode;
  81. public:
  82. virtual BOOL OnInitDialog();
  83. afx_msg void OnClose();
  84. private:
  85. // 当前选中的检查模式
  86. CComboBox m_examMode;
  87. public:
  88. afx_msg void OnBnClickedButtonInsertTubeAngle();
  89. afx_msg void OnBnClickedButtonInsertTubeHeight();
  90. afx_msg void OnBnClickedButtonInsertDetectorHeight();
  91. private:
  92. // 当前物理角度
  93. CEdit m_autoadTubeAngleCurrent;
  94. CEdit m_autoadTubeAngleHighlimit;
  95. CEdit m_autoadTubeAngleLowlimit;
  96. CEdit m_autoadTubeHeightCurrent;
  97. CEdit m_autoadTubeHeightHighlimit;
  98. CEdit m_autoadTubeHeightLowlimit;
  99. int m_tubeAngleSvoStatus;
  100. int m_tubeHeightSvoStatus;
  101. public:
  102. afx_msg void OnBnClickedButtonAutoCaladTubeangle();
  103. afx_msg void OnBnClickedButtonAutoCaladTubeheight();
  104. afx_msg void OnBnClickedTubeAngleSvo();
  105. afx_msg void OnBnClickedButtonTubeheightSvo();
  106. private:
  107. CComboBox m_selftestDOF;
  108. CEdit m_selftestHighlimit;
  109. CEdit m_selftestlowlimit;
  110. CEdit m_selftestperiod;
  111. CEdit m_selftestdutycycle;
  112. CEdit m_selftestRepeatTime;
  113. };