您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 

431 行
10 KiB

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <ui version="4.0">
  3. <class>Widget</class>
  4. <widget class="QWidget" name="Widget">
  5. <property name="geometry">
  6. <rect>
  7. <x>0</x>
  8. <y>0</y>
  9. <width>700</width>
  10. <height>500</height>
  11. </rect>
  12. </property>
  13. <property name="windowTitle">
  14. <string>Widget</string>
  15. </property>
  16. <widget class="QGroupBox" name="groupBox">
  17. <property name="geometry">
  18. <rect>
  19. <x>30</x>
  20. <y>260</y>
  21. <width>181</width>
  22. <height>231</height>
  23. </rect>
  24. </property>
  25. <property name="title">
  26. <string>从站配置</string>
  27. </property>
  28. <widget class="QWidget" name="layoutWidget">
  29. <property name="geometry">
  30. <rect>
  31. <x>10</x>
  32. <y>30</y>
  33. <width>159</width>
  34. <height>141</height>
  35. </rect>
  36. </property>
  37. <layout class="QGridLayout" name="gridLayout_2">
  38. <item row="0" column="0">
  39. <widget class="QLabel" name="label_9">
  40. <property name="text">
  41. <string>站地址</string>
  42. </property>
  43. </widget>
  44. </item>
  45. <item row="1" column="0">
  46. <widget class="QLabel" name="label_10">
  47. <property name="text">
  48. <string>操作</string>
  49. </property>
  50. </widget>
  51. </item>
  52. <item row="1" column="1">
  53. <widget class="QComboBox" name="comboBox_gongnengma">
  54. <item>
  55. <property name="text">
  56. <string>读线圈</string>
  57. </property>
  58. </item>
  59. <item>
  60. <property name="text">
  61. <string>读寄存器</string>
  62. </property>
  63. </item>
  64. <item>
  65. <property name="text">
  66. <string>写线圈</string>
  67. </property>
  68. </item>
  69. <item>
  70. <property name="text">
  71. <string>写寄存器</string>
  72. </property>
  73. </item>
  74. </widget>
  75. </item>
  76. <item row="2" column="0">
  77. <widget class="QLabel" name="label_11">
  78. <property name="text">
  79. <string>起始地址</string>
  80. </property>
  81. </widget>
  82. </item>
  83. <item row="2" column="1">
  84. <widget class="QLineEdit" name="lineEdit_stratAddress">
  85. <property name="text">
  86. <string>256</string>
  87. </property>
  88. </widget>
  89. </item>
  90. <item row="3" column="0">
  91. <widget class="QLabel" name="label_12">
  92. <property name="text">
  93. <string>长度</string>
  94. </property>
  95. </widget>
  96. </item>
  97. <item row="3" column="1">
  98. <widget class="QLineEdit" name="lineEdit_length">
  99. <property name="text">
  100. <string>1</string>
  101. </property>
  102. </widget>
  103. </item>
  104. <item row="0" column="1">
  105. <widget class="QLineEdit" name="lineEdit_stationAddress">
  106. <property name="text">
  107. <string>1</string>
  108. </property>
  109. </widget>
  110. </item>
  111. </layout>
  112. </widget>
  113. <widget class="QPushButton" name="btn_read">
  114. <property name="geometry">
  115. <rect>
  116. <x>10</x>
  117. <y>170</y>
  118. <width>71</width>
  119. <height>51</height>
  120. </rect>
  121. </property>
  122. <property name="text">
  123. <string>读</string>
  124. </property>
  125. </widget>
  126. <widget class="QPushButton" name="pushWrite">
  127. <property name="geometry">
  128. <rect>
  129. <x>90</x>
  130. <y>170</y>
  131. <width>71</width>
  132. <height>51</height>
  133. </rect>
  134. </property>
  135. <property name="text">
  136. <string>写</string>
  137. </property>
  138. </widget>
  139. </widget>
  140. <widget class="QGroupBox" name="groupBox_2">
  141. <property name="geometry">
  142. <rect>
  143. <x>30</x>
  144. <y>19</y>
  145. <width>181</width>
  146. <height>221</height>
  147. </rect>
  148. </property>
  149. <property name="title">
  150. <string>串口配置</string>
  151. </property>
  152. <layout class="QFormLayout" name="formLayout">
  153. <item row="0" column="0">
  154. <layout class="QGridLayout" name="gridLayout">
  155. <item row="0" column="0">
  156. <widget class="QLabel" name="label">
  157. <property name="text">
  158. <string>串口</string>
  159. </property>
  160. </widget>
  161. </item>
  162. <item row="0" column="1">
  163. <widget class="QComboBox" name="comboBox_serialNum"/>
  164. </item>
  165. <item row="1" column="0">
  166. <widget class="QLabel" name="label_2">
  167. <property name="text">
  168. <string>波特率</string>
  169. </property>
  170. </widget>
  171. </item>
  172. <item row="1" column="1">
  173. <widget class="QComboBox" name="comboBox_baudRate">
  174. <item>
  175. <property name="text">
  176. <string>1200</string>
  177. </property>
  178. </item>
  179. <item>
  180. <property name="text">
  181. <string>2400</string>
  182. </property>
  183. </item>
  184. <item>
  185. <property name="text">
  186. <string>4800</string>
  187. </property>
  188. </item>
  189. <item>
  190. <property name="text">
  191. <string>9600</string>
  192. </property>
  193. </item>
  194. <item>
  195. <property name="text">
  196. <string>19200</string>
  197. </property>
  198. </item>
  199. <item>
  200. <property name="text">
  201. <string>38400</string>
  202. </property>
  203. </item>
  204. </widget>
  205. </item>
  206. <item row="2" column="0">
  207. <widget class="QLabel" name="label_3">
  208. <property name="text">
  209. <string>数据位</string>
  210. </property>
  211. </widget>
  212. </item>
  213. <item row="2" column="1">
  214. <widget class="QComboBox" name="comboBox_dataBit">
  215. <item>
  216. <property name="text">
  217. <string>5</string>
  218. </property>
  219. </item>
  220. <item>
  221. <property name="text">
  222. <string>6</string>
  223. </property>
  224. </item>
  225. <item>
  226. <property name="text">
  227. <string>7</string>
  228. </property>
  229. </item>
  230. <item>
  231. <property name="text">
  232. <string>8</string>
  233. </property>
  234. </item>
  235. </widget>
  236. </item>
  237. <item row="3" column="0">
  238. <widget class="QLabel" name="label_7">
  239. <property name="text">
  240. <string>校验位</string>
  241. </property>
  242. </widget>
  243. </item>
  244. <item row="3" column="1">
  245. <widget class="QComboBox" name="comboBox_xiaoyan">
  246. <item>
  247. <property name="text">
  248. <string>无校验(N)</string>
  249. </property>
  250. </item>
  251. <item>
  252. <property name="text">
  253. <string>奇校验(O)</string>
  254. </property>
  255. </item>
  256. <item>
  257. <property name="text">
  258. <string>偶校验(E)</string>
  259. </property>
  260. </item>
  261. </widget>
  262. </item>
  263. <item row="4" column="0">
  264. <widget class="QLabel" name="label_8">
  265. <property name="text">
  266. <string>停止位</string>
  267. </property>
  268. </widget>
  269. </item>
  270. <item row="4" column="1">
  271. <widget class="QComboBox" name="comboBox_stopBit">
  272. <item>
  273. <property name="text">
  274. <string>1</string>
  275. </property>
  276. </item>
  277. <item>
  278. <property name="text">
  279. <string>2</string>
  280. </property>
  281. </item>
  282. </widget>
  283. </item>
  284. <item row="5" column="0" colspan="2">
  285. <widget class="QPushButton" name="btnConnect">
  286. <property name="text">
  287. <string>连接</string>
  288. </property>
  289. </widget>
  290. </item>
  291. </layout>
  292. </item>
  293. </layout>
  294. </widget>
  295. <widget class="QGroupBox" name="groupBox_3">
  296. <property name="geometry">
  297. <rect>
  298. <x>240</x>
  299. <y>20</y>
  300. <width>211</width>
  301. <height>271</height>
  302. </rect>
  303. </property>
  304. <property name="title">
  305. <string>数据读取</string>
  306. </property>
  307. <widget class="QTextEdit" name="textEdit">
  308. <property name="geometry">
  309. <rect>
  310. <x>10</x>
  311. <y>20</y>
  312. <width>191</width>
  313. <height>241</height>
  314. </rect>
  315. </property>
  316. <property name="readOnly">
  317. <bool>true</bool>
  318. </property>
  319. </widget>
  320. </widget>
  321. <widget class="QGroupBox" name="groupBox_4">
  322. <property name="geometry">
  323. <rect>
  324. <x>470</x>
  325. <y>20</y>
  326. <width>221</width>
  327. <height>271</height>
  328. </rect>
  329. </property>
  330. <property name="title">
  331. <string>状态通知</string>
  332. </property>
  333. <widget class="QTextEdit" name="textEdit_2">
  334. <property name="geometry">
  335. <rect>
  336. <x>10</x>
  337. <y>20</y>
  338. <width>201</width>
  339. <height>241</height>
  340. </rect>
  341. </property>
  342. <property name="readOnly">
  343. <bool>true</bool>
  344. </property>
  345. </widget>
  346. </widget>
  347. <widget class="QGroupBox" name="groupBox_5">
  348. <property name="geometry">
  349. <rect>
  350. <x>240</x>
  351. <y>340</y>
  352. <width>341</width>
  353. <height>151</height>
  354. </rect>
  355. </property>
  356. <property name="title">
  357. <string>写入数据</string>
  358. </property>
  359. <widget class="QLabel" name="label_13">
  360. <property name="geometry">
  361. <rect>
  362. <x>10</x>
  363. <y>20</y>
  364. <width>311</width>
  365. <height>91</height>
  366. </rect>
  367. </property>
  368. <property name="text">
  369. <string>写线圈时,使用1、0代表线圈的开关状态,
  370. 从左到右依次输入每个线圈的开关;
  371. 写寄存器时要同时写入所有寄存器的数值,
  372. 相邻寄存器的值之间用英文&quot;,&quot;分离。</string>
  373. </property>
  374. </widget>
  375. <widget class="QLineEdit" name="lineEdit">
  376. <property name="geometry">
  377. <rect>
  378. <x>10</x>
  379. <y>110</y>
  380. <width>301</width>
  381. <height>31</height>
  382. </rect>
  383. </property>
  384. </widget>
  385. </widget>
  386. <widget class="QWidget" name="layoutWidget">
  387. <property name="geometry">
  388. <rect>
  389. <x>240</x>
  390. <y>300</y>
  391. <width>451</width>
  392. <height>30</height>
  393. </rect>
  394. </property>
  395. <layout class="QHBoxLayout" name="horizontalLayout">
  396. <item>
  397. <widget class="QPushButton" name="btn_ClearRead">
  398. <property name="text">
  399. <string>清空读取信息</string>
  400. </property>
  401. </widget>
  402. </item>
  403. <item>
  404. <widget class="QPushButton" name="btn_ClearDate">
  405. <property name="text">
  406. <string>清空收发信息</string>
  407. </property>
  408. </widget>
  409. </item>
  410. <item>
  411. <widget class="QPushButton" name="btn_ReadDate">
  412. <property name="text">
  413. <string>读取历史收发信息</string>
  414. </property>
  415. </widget>
  416. </item>
  417. <item>
  418. <widget class="QPushButton" name="btn_SaveDate">
  419. <property name="text">
  420. <string>保存收发信息</string>
  421. </property>
  422. </widget>
  423. </item>
  424. </layout>
  425. </widget>
  426. </widget>
  427. <layoutdefault spacing="6" margin="11"/>
  428. <resources/>
  429. <connections/>
  430. </ui>