综合平台编程器项目的远程存储
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

126 lines
8.5 KiB

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <ui version="4.0">
  3. <class>PlcConnectionDialog</class>
  4. <widget class="QDialog" name="PlcConnectionDialog">
  5. <property name="windowTitle">
  6. <string>PLC 通信配置</string>
  7. </property>
  8. <property name="minimumSize">
  9. <size><width>440</width><height>0</height></size>
  10. </property>
  11. <layout class="QVBoxLayout" name="dialogLayout">
  12. <item>
  13. <widget class="QGroupBox" name="serialGroupBox">
  14. <property name="title"><string>Modbus RTU 串口</string></property>
  15. <layout class="QVBoxLayout" name="serialGroupLayout">
  16. <item>
  17. <layout class="QHBoxLayout" name="discoveryControlLayout">
  18. <item>
  19. <widget class="QPushButton" name="autoSearchButton">
  20. <property name="text"><string>自动搜索</string></property>
  21. </widget>
  22. </item>
  23. <item>
  24. <widget class="QProgressBar" name="discoveryProgressBar">
  25. <property name="minimum"><number>0</number></property>
  26. <property name="maximum"><number>100</number></property>
  27. <property name="value"><number>0</number></property>
  28. <property name="textVisible"><bool>false</bool></property>
  29. </widget>
  30. </item>
  31. </layout>
  32. </item>
  33. <item>
  34. <widget class="QLabel" name="discoveryStatusLabel">
  35. <property name="text"><string>自动搜索使用当前 PLC 站号</string></property>
  36. <property name="wordWrap"><bool>true</bool></property>
  37. </widget>
  38. </item>
  39. <item>
  40. <layout class="QFormLayout" name="serialFormLayout">
  41. <property name="fieldGrowthPolicy"><enum>QFormLayout::AllNonFixedFieldsGrow</enum></property>
  42. <item row="0" column="0"><widget class="QLabel" name="serialPortLabel"><property name="text"><string>端口</string></property></widget></item>
  43. <item row="0" column="1">
  44. <layout class="QHBoxLayout" name="serialPortEditorLayout">
  45. <item>
  46. <widget class="QComboBox" name="serialPortComboBox">
  47. <property name="editable"><bool>true</bool></property>
  48. <property name="placeholderText"><string>选择或输入 COM 端口</string></property>
  49. </widget>
  50. </item>
  51. <item>
  52. <widget class="QToolButton" name="refreshPortsButton">
  53. <property name="minimumSize"><size><width>28</width><height>28</height></size></property>
  54. <property name="maximumSize"><size><width>28</width><height>28</height></size></property>
  55. <property name="toolTip"><string>刷新串口</string></property>
  56. <property name="accessibleName"><string>刷新串口</string></property>
  57. <property name="autoRaise"><bool>true</bool></property>
  58. </widget>
  59. </item>
  60. </layout>
  61. </item>
  62. <item row="1" column="0"><widget class="QLabel" name="serverAddressLabel"><property name="text"><string>PLC 站号</string></property></widget></item>
  63. <item row="1" column="1"><widget class="QSpinBox" name="serverAddressSpinBox"><property name="minimum"><number>1</number></property><property name="maximum"><number>247</number></property></widget></item>
  64. <item row="2" column="0"><widget class="QLabel" name="baudRateLabel"><property name="text"><string>波特率</string></property></widget></item>
  65. <item row="2" column="1">
  66. <widget class="QComboBox" name="baudRateComboBox">
  67. <item><property name="text"><string>9600</string></property><property name="userData"><string notr="true">9600</string></property></item>
  68. <item><property name="text"><string>19200</string></property><property name="userData"><string notr="true">19200</string></property></item>
  69. <item><property name="text"><string>38400</string></property><property name="userData"><string notr="true">38400</string></property></item>
  70. <item><property name="text"><string>57600</string></property><property name="userData"><string notr="true">57600</string></property></item>
  71. <item><property name="text"><string>115200</string></property><property name="userData"><string notr="true">115200</string></property></item>
  72. </widget>
  73. </item>
  74. <item row="3" column="0"><widget class="QLabel" name="dataBitsLabel"><property name="text"><string>数据位</string></property></widget></item>
  75. <item row="3" column="1">
  76. <widget class="QComboBox" name="dataBitsComboBox">
  77. <item><property name="text"><string>7</string></property><property name="userData"><string notr="true">7</string></property></item>
  78. <item><property name="text"><string>8</string></property><property name="userData"><string notr="true">8</string></property></item>
  79. </widget>
  80. </item>
  81. <item row="4" column="0"><widget class="QLabel" name="parityLabel"><property name="text"><string>校验方式</string></property></widget></item>
  82. <item row="4" column="1">
  83. <widget class="QComboBox" name="parityComboBox">
  84. <item><property name="text"><string>无校验</string></property><property name="userData"><string notr="true">0</string></property></item>
  85. <item><property name="text"><string>奇校验</string></property><property name="userData"><string notr="true">3</string></property></item>
  86. <item><property name="text"><string>偶校验</string></property><property name="userData"><string notr="true">2</string></property></item>
  87. </widget>
  88. </item>
  89. <item row="5" column="0"><widget class="QLabel" name="stopBitsLabel"><property name="text"><string>停止位</string></property></widget></item>
  90. <item row="5" column="1">
  91. <widget class="QComboBox" name="stopBitsComboBox">
  92. <item><property name="text"><string>1</string></property><property name="userData"><string notr="true">1</string></property></item>
  93. <item><property name="text"><string>2</string></property><property name="userData"><string notr="true">2</string></property></item>
  94. </widget>
  95. </item>
  96. </layout>
  97. </item>
  98. </layout>
  99. </widget>
  100. </item>
  101. <item>
  102. <widget class="QGroupBox" name="timingGroupBox">
  103. <property name="title"><string>通信时序</string></property>
  104. <layout class="QFormLayout" name="timingFormLayout">
  105. <item row="0" column="0"><widget class="QLabel" name="responseTimeoutLabel"><property name="text"><string>响应超时</string></property></widget></item>
  106. <item row="0" column="1"><widget class="QSpinBox" name="responseTimeoutSpinBox"><property name="suffix"><string> ms</string></property><property name="minimum"><number>100</number></property><property name="maximum"><number>30000</number></property><property name="singleStep"><number>100</number></property><property name="value"><number>1000</number></property></widget></item>
  107. <item row="1" column="0"><widget class="QLabel" name="retriesLabel"><property name="text"><string>失败重试</string></property></widget></item>
  108. <item row="1" column="1"><widget class="QSpinBox" name="retriesSpinBox"><property name="suffix"><string> 次</string></property><property name="maximum"><number>5</number></property><property name="value"><number>2</number></property></widget></item>
  109. <item row="2" column="0"><widget class="QLabel" name="pollIntervalLabel"><property name="text"><string>轮询周期</string></property></widget></item>
  110. <item row="2" column="1"><widget class="QSpinBox" name="pollIntervalSpinBox"><property name="suffix"><string> ms</string></property><property name="minimum"><number>50</number></property><property name="maximum"><number>10000</number></property><property name="singleStep"><number>50</number></property><property name="value"><number>200</number></property></widget></item>
  111. </layout>
  112. </widget>
  113. </item>
  114. <item>
  115. <widget class="QDialogButtonBox" name="buttonBox">
  116. <property name="standardButtons"><set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set></property>
  117. </widget>
  118. </item>
  119. </layout>
  120. </widget>
  121. <connections>
  122. <connection><sender>buttonBox</sender><signal>accepted()</signal><receiver>PlcConnectionDialog</receiver><slot>accept()</slot><hints><hint type="sourcelabel"><x>320</x><y>360</y></hint><hint type="destinationlabel"><x>210</x><y>180</y></hint></hints></connection>
  123. <connection><sender>buttonBox</sender><signal>rejected()</signal><receiver>PlcConnectionDialog</receiver><slot>reject()</slot><hints><hint type="sourcelabel"><x>320</x><y>360</y></hint><hint type="destinationlabel"><x>210</x><y>180</y></hint></hints></connection>
  124. </connections>
  125. </ui>