WCS_PLC.cs 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. using SqlSugar;
  2. using System;
  3. namespace WCS.Entity
  4. {
  5. /// <summary>
  6. /// WCS_PLC
  7. /// </summary>
  8. [SugarTable(nameof(WCS_PLC), "PLC信息")]
  9. public class WCS_PLC : OBJ
  10. {
  11. [SugarColumn(IsIgnore = true)]
  12. [Obsolete]
  13. public override int ID { get; set; }
  14. /// <summary>
  15. /// 编号
  16. /// </summary>
  17. [SugarColumn(IsPrimaryKey = true, ColumnDescription = "编号", Length = 20)]
  18. public string CODE { get; set; }
  19. /// <summary>
  20. /// 名称
  21. /// </summary>
  22. [SugarColumn(ColumnDescription = "名称", Length = 20)]
  23. public string NAME { get; set; }
  24. /// <summary>
  25. /// IP
  26. /// </summary>
  27. [SugarColumn(ColumnDescription = "IP", Length = 20)]
  28. public string IP { get; set; }
  29. /// <summary>
  30. /// 端口
  31. /// </summary>
  32. [SugarColumn(ColumnDescription = "端口")]
  33. public int PORT { get; set; } = 102;
  34. /// <summary>
  35. /// 插槽号
  36. /// </summary>
  37. [SugarColumn(ColumnDescription = "插槽号")]
  38. public int SLOT { get; set; }
  39. /// <summary>
  40. /// 机架号
  41. /// </summary>
  42. [SugarColumn(ColumnDescription = "机架号")]
  43. public int RACK { get; set; }
  44. /// <summary>
  45. /// 厂商
  46. /// </summary>
  47. [SugarColumn(ColumnDescription = "厂商")]
  48. public PLCType TYPE { get; set; }
  49. /// <summary>
  50. /// 型号
  51. /// </summary>
  52. [SugarColumn(ColumnDescription = "型号")]
  53. public PLCMODEL MODEL { get; set; }
  54. }
  55. /// <summary>
  56. /// 设备厂商
  57. /// </summary>
  58. public enum PLCType
  59. {
  60. /// <summary>
  61. /// 西门子
  62. /// </summary>
  63. Siemens = 1,
  64. /// <summary>
  65. /// 三菱
  66. /// </summary>
  67. Mitsubishi = 2,
  68. /// <summary>
  69. /// AB
  70. /// </summary>
  71. AB = 3,
  72. /// <summary>
  73. /// 欧姆龙
  74. /// </summary>
  75. OMRON = 4,
  76. /// <summary>
  77. /// 汇川
  78. /// </summary>
  79. INOVANCE = 5,
  80. }
  81. /// <summary>
  82. /// PLC型号
  83. /// </summary>
  84. public enum PLCMODEL
  85. {
  86. #region 西门子
  87. /// <summary>
  88. /// 1200系列
  89. /// </summary>
  90. S1200 = 1,
  91. /// <summary>
  92. /// 300系列
  93. /// </summary>
  94. S300 = 2,
  95. /// <summary>
  96. /// 400系列
  97. /// </summary>
  98. S400 = 3,
  99. /// <summary>
  100. /// 1500系列PLC
  101. /// </summary>
  102. S1500 = 4,
  103. /// <summary>
  104. /// 200的smart系列
  105. /// </summary>
  106. S200Smart = 5,
  107. /// <summary>
  108. /// 200系统,需要额外配置以太网模块
  109. /// </summary>
  110. S200 = 6
  111. #endregion 西门子
  112. }
  113. }