AITAPCData.cs 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. 
  2. namespace OldWorldData.CommonData.DeviceData
  3. {
  4. [DataContract]
  5. [Serializable]
  6. public class AITAPCData
  7. {
  8. [DataMember]
  9. public string Module { get; set; }
  10. [DataMember]
  11. public string DeviceName { get; set; }
  12. [DataMember]
  13. public string DisplayName { get; set; }
  14. [DataMember]
  15. public string DeviceSchematicId { get; set; }
  16. [DataMember]
  17. public string UnitPosition { get; set; }
  18. [DataMember]
  19. public string UnitPressure { get; set; }
  20. [DataMember]
  21. public string Description { get; set; }
  22. /// <summary>
  23. /// 量程
  24. /// </summary>
  25. [DataMember]
  26. public double MaxValuePosition { get; set; }
  27. [DataMember]
  28. public double MaxValuePressure { get; set; }
  29. /// <summary>
  30. /// MFC,PC
  31. /// </summary>
  32. [DataMember]
  33. public string Type { get; set; }
  34. [DataMember]
  35. public int ModeFeedback { get; set; }
  36. [DataMember]
  37. public int ModeSetPoint { get; set; }
  38. [DataMember]
  39. public float PositionFeedback { get; set; }
  40. [DataMember]
  41. public float PressureFeedback { get; set; }
  42. [DataMember]
  43. public float Pressure1Feedback { get; set; }
  44. [DataMember]
  45. public float Pressure2Feedback { get; set; }
  46. [DataMember]
  47. public float PressureSetPoint { get; set; }//界面设定
  48. [DataMember]
  49. public float PositionSetPoint { get; set; }//界面设定
  50. [DataMember]
  51. public float SlowRateSetPoint { get; set; }//界面设定
  52. [DataMember]
  53. public float SlowTargetPressureSetPoint { get; set; }//界面设定
  54. [DataMember]
  55. public int State { get; set; }
  56. [DataMember]
  57. public int HomingStatus { get; set; }
  58. [DataMember]
  59. public int SelectedControllerFeedback { get; set; }
  60. [DataMember]
  61. public int SelectedControllerSetPoint { get; set; }//界面设定
  62. [DataMember]
  63. public string PIDTable//界面设定
  64. {
  65. get;
  66. set;
  67. }
  68. [DataMember]
  69. public string AlarmWatchTable
  70. {
  71. get;
  72. set;
  73. }
  74. [DataMember]
  75. public float SetPoint { get; set; }//界面设定
  76. [DataMember]
  77. public string CommandSetPoint { get; set; }//界面设定
  78. [DataMember]
  79. public string LowPressWaitSetPoint { get; set; }//界面设定
  80. [DataMember]
  81. public string HardError { get; set; }
  82. [DataMember]
  83. public string HomeStatusDisplay { get; set; }
  84. public string TextModeSetPoint
  85. {
  86. get
  87. {
  88. return ModeSetPoint switch
  89. {
  90. (int)(PressureControlMode.PositionControl) => "Valve Angle",
  91. (int)(PressureControlMode.Press1Control) => "Press1",
  92. (int)(PressureControlMode.Press2Control) => "Press2",
  93. (int)(PressureControlMode.Open) => "Full Open",
  94. (int)(PressureControlMode.Close) => "Full Close",
  95. (int)(PressureControlMode.SlowVacuum) => "Slow Vac",
  96. (int)(PressureControlMode.Hold) => "Hold",
  97. (int)(PressureControlMode.Homing) => "Homing",
  98. _ => "Idle",
  99. };
  100. }
  101. }
  102. public string TextModeFeedback
  103. {
  104. get
  105. {
  106. return ModeFeedback switch
  107. {
  108. (int)(PressureControlMode.PositionControl) => "Valve Angle",
  109. (int)(PressureControlMode.Press1Control) => "Press1",
  110. (int)(PressureControlMode.Press2Control) => "Press2",
  111. (int)(PressureControlMode.Open) => "Full Open",
  112. (int)(PressureControlMode.Close) => "Full Close",
  113. (int)(PressureControlMode.SlowVacuum) => "Slow Vac",
  114. (int)(PressureControlMode.Hold) => "Hold",
  115. (int)(PressureControlMode.Homing) => "Homing",
  116. _ => "Idle",
  117. };
  118. }
  119. }
  120. public AITAPCData()
  121. {
  122. DisplayName = "Undefined";
  123. UnitPosition = "%";
  124. UnitPressure = "mTorr";
  125. Type = "TV";
  126. MaxValuePosition = 100;
  127. MaxValuePressure = 1000;
  128. }
  129. public enum APCUnitEnum
  130. {
  131. Torr,
  132. Pa
  133. }
  134. public enum APCModeTypeEnum
  135. {
  136. [Description("APCCKD")]
  137. APCCKD,
  138. [Description("VAT+GV")]
  139. APCVATGV,
  140. [Description("Dual APC")]
  141. DUAL
  142. }
  143. }
  144. }