auto_D.html 40 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732
  1. <!-- 宣告我們要套用模板 -->
  2. {% extends "base.html" %}
  3. {% block title %}{{ title }}{% endblock %}
  4. {% block script %}
  5. <script language="JavaScript">
  6. function myrefresh()
  7. {
  8. $.get('/dry_auto_data', function (resText) {
  9. var DI = [resText.DI1,resText.DI2];
  10. var D=[resText.D1,resText.D2,resText.D3,resText.D4,resText.D5,resText.D6,resText.D7,resText.D8,resText.D9,resText.D10,resText.D11,resText.D12];
  11. var DO = [resText.DO1,resText.DO2];
  12. var a=[resText.vacuum_input,resText.vacuum,resText.threewayvalve_input,resText.diskvalve,resText.solenoid_disinfect,resText.solenoid_outer_water,resText.motor,resText.vacuum_pump,resText.heater1,resText.heater2,resText.vacuum_output]
  13. for (let i=0; i<2; i++) {
  14. if (DI[i] == 'DI_InputtingBean') {
  15. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  16. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 入豆中")
  17. } else if (DI[i] == 'DI_Waiting') {
  18. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  19. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 空桶等待")
  20. } else if (DI[i] == 'DI_OutputtingBean') {
  21. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  22. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 可出豆")
  23. } else if (DI[i] == 'DI_Stand_by') {
  24. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  25. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 待命")
  26. } else {
  27. console.log('pass')
  28. }
  29. }
  30. for (let i=0; i<12; i++) {
  31. if (D[i] == 'D_InputtingBean') {
  32. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  33. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆中")
  34. } else if (D[i] == 'D_InputtingBean_Pause') {
  35. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  36. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆暫停")
  37. } else if (D[i] == 'D_InputtingBean_Finish') {
  38. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  39. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆完成")
  40. } else if (D[i] == 'D_Waiting') {
  41. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  42. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 空桶等待")
  43. } else if (D[i] == 'D_InputtingWater') {
  44. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "DeepSkyBlue")
  45. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 外桶入水中")
  46. } else if (D[i] == 'D_Cleaning') {
  47. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "plum")
  48. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 清洗中")
  49. } else if (D[i] == 'D_Drying') {
  50. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "Peru")
  51. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 乾燥中")
  52. } else if (D[i] == 'D_OutputtingBean') {
  53. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  54. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 可出豆")
  55. } else if (D[i] == 'D_Warning') {
  56. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "crimson")
  57. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 發生錯誤")
  58. $("#D"+parseInt(i+1)+"_status").css("color", "crimson")
  59. } else if (D[i] == 'D_Stand_by') {
  60. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  61. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 待命")
  62. } else {
  63. console.log('pass')
  64. }
  65. }
  66. for (let i=0; i<2; i++) {
  67. if (DO[i] == 'DO_InputtingBean') {
  68. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  69. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 入豆中")
  70. } else if (DO[i] == 'DO_Waiting') {
  71. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  72. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 空桶等待")
  73. } else if (DO[i] == 'DO_OutputtingBean') {
  74. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  75. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 可出豆")
  76. } else if (DO[i] == 'DO_Stand_by') {
  77. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  78. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 待命")
  79. } else {
  80. console.log('pass')
  81. }
  82. }
  83. },'json');
  84. loading_D()
  85. }
  86. setInterval('myrefresh()',1000);
  87. </script>
  88. <script>
  89. var status = '{{status}}';
  90. var username = '{{username}}';
  91. $(document).ready(function(){
  92. $("#coffee_title_pc").text('乾燥自動化');
  93. $("#coffee_title_phone").text('乾燥自動化');
  94. $('#navbarDropdown_user_pc').text(username);
  95. $('#navbarDropdown_user_phone').text(username);
  96. // 桶槽入料顯示
  97. dry_input_status_N = ['{{DI1}}', '{{DI2}}']
  98. for (let i=0; i<dry_input_status_N.length; i++) {
  99. if (dry_input_status_N[i] == 'DI_InputtingBean') {
  100. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  101. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 入豆中")
  102. } else if (dry_input_status_N[i] == 'DI_Waiting') {
  103. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  104. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 空桶等待")
  105. } else if (dry_input_status_N[i] == 'DI_OutputtingBean') {
  106. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  107. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 可出豆")
  108. } else if (dry_input_status_N[i] == 'DI_Stand_by') {
  109. $("#DI"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  110. $("#DI"+parseInt(i+1)+"_status").text("DI" + parseInt(i+1) + " 待命")
  111. } else {
  112. console.log('pass')
  113. }
  114. }
  115. // 桶槽狀態顯示
  116. dry_tank_status_N = ['{{D1}}', '{{D2}}', '{{D3}}', '{{D4}}', '{{D5}}', '{{D6}}',
  117. '{{D7}}', '{{D8}}', '{{D9}}', '{{D10}}', '{{D11}}', '{{D12}}']
  118. for (let i=0; i<dry_tank_status_N.length; i++) {
  119. if (dry_tank_status_N[i] == 'D_InputtingBean') {
  120. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  121. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆中")
  122. } else if (dry_tank_status_N[i] == 'D_InputtingBean_Pause') {
  123. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  124. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆暫停")
  125. } else if (dry_tank_status_N[i] == 'D_InputtingBean_Finish') {
  126. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  127. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 入豆完成")
  128. } else if (dry_tank_status_N[i] == 'D_InputtingWater') {
  129. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "DeepSkyBlue")
  130. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + "外桶入水中")
  131. } else if (dry_tank_status_N[i] == 'D_Waiting') {
  132. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  133. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 空桶等待")
  134. } else if (dry_tank_status_N[i] == 'D_Cleaning') {
  135. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "plum")
  136. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 清洗中")
  137. } else if (dry_tank_status_N[i] == 'D_Drying') {
  138. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "Peru")
  139. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 乾燥中")
  140. } else if (dry_tank_status_N[i] == 'D_OutputtingBean') {
  141. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  142. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 可出豆")
  143. } else if (dry_tank_status_N[i] == 'D_Warning') {
  144. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "crimson")
  145. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 發生錯誤")
  146. $("#D"+parseInt(i+1)+"_status").css("color", "crimson")
  147. } else if (dry_input_status_N[i] == 'D_Stand_by') {
  148. $("#D"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  149. $("#D"+parseInt(i+1)+"_status").text("D" + parseInt(i+1) + " 待命")
  150. } else {
  151. console.log('pass')
  152. }
  153. }
  154. // 桶槽出料顯示
  155. dry_output_status_N = ['{{DO1}}', '{{DO2}}']
  156. for (let i=0; i<dry_output_status_N.length; i++) {
  157. if (dry_output_status_N[i] == 'DO_InputtingBean') {
  158. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  159. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 入豆中")
  160. } else if (dry_output_status_N[i] == 'DO_Waiting') {
  161. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "lightgray")
  162. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 空桶等待")
  163. } else if (dry_output_status_N[i] == 'DO_OutputtingBean') {
  164. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "MediumSeaGreen")
  165. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 可出豆")
  166. } else if (dry_output_status_N[i] == 'DO_Stand_by') {
  167. $("#DO"+parseInt(i+1)+"_status_dot").css("background-color", "HotPink")
  168. $("#DO"+parseInt(i+1)+"_status").text("DO" + parseInt(i+1) + " 待命")
  169. } else {
  170. console.log('pass')
  171. }
  172. }
  173. loading_D()
  174. });
  175. function loading_D(){
  176. var dtid = '{{dtid}}';
  177. $.get('/loading/D'+dtid, '', function (resText) {
  178. var a=[resText.vacuum,resText.threewayvalve_input,resText.diskvalve,resText.solenoid_outer_water,resText.solenoid_disinfect,resText.solenoid_water_out,resText.motor,resText.vacuum_pump,resText.heater1,resText.heater2,resText.warning_light]
  179. for (let i=0; i<11; i++) {
  180. if (a[i] == 1) {
  181. $("#actuator_"+parseInt(i)+"_status").css("background-color", "MediumSeaGreen")
  182. } else if (a[i] == 0) {
  183. $("#actuator_"+parseInt(i)+"_status").css("background-color", "lightgray")
  184. }
  185. else {
  186. $("#actuator_"+parseInt(i)+"_status").css("background-color", "crimson")
  187. }
  188. }
  189. $("#sensor_1").text(resText.UltraSonic);
  190. $("#sensor_2").text(resText.SHT11_Temp);
  191. $("#sensor_3").text(resText.SHT11_Humidity);
  192. $("#sensor_4").text(resText.soil_Temp);
  193. $("#sensor_5").text(resText.soil_Humidity);
  194. $("#sensor_6").text(resText.soil_EC);
  195. $("#sensor_7").text(resText.PA);
  196. $("#sensor_8").text(resText.motorEncoder);
  197. $("#sensor_9").text(resText.butterflyvalve);
  198. $("#sensor_10").text(resText.WaterLevel);
  199. }, 'json');
  200. };
  201. </script>
  202. {% endblock %}
  203. {% block style %}
  204. <style>
  205. .D_status_css {
  206. font-weight: bold;
  207. text-align: center;
  208. }
  209. .input-text {
  210. height: 25px;
  211. width: 40px;
  212. text-align: center;
  213. margin-left: 2px;
  214. margin-right: 5px;
  215. }
  216. </style>
  217. {% endblock %}
  218. {% block main %}
  219. <div class="album py-5 bg-light">
  220. <div class="container">
  221. <div class="row row-cols-1 row-cols-sm-1 row-cols-md-1 g-3">
  222. <div class="col">
  223. <div class="card shadow-sm">
  224. <div class="card-body">
  225. <div class="d-flex justify-content-between align-items-center">
  226. <table style="border: 3px lightsteelblue solid; margin-right: auto; margin-left: auto; text-align: center; margin-top: 5px;" cellpadding="5" border="1">
  227. <div style="text-align: center;">
  228. <tr>
  229. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  230. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  231. <tr>
  232. <td>
  233. <div id="DI1" tabindex="0" class="DI1_position" role="button" style="text-align: center;">
  234. <span id="DI1_status" class="D_status_css">DI1 status</span>
  235. </div>
  236. </td>
  237. </tr>
  238. </table>
  239. </td>
  240. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  241. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  242. <tr>
  243. <td>
  244. <div id="D1" tabindex="0" class="D1_position" role="button">
  245. <span id="D1_status" class="D_status_css">D1 status</span>
  246. <!-- D1 狀態點點-->
  247. </div>
  248. </td>
  249. </tr>
  250. </table>
  251. </td>
  252. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  253. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  254. <tr>
  255. <td>
  256. <div id="D2" tabindex="0" class="D2_position" role="button">
  257. <span id="D2_status" class="D_status_css">D2 status</span>
  258. </div>
  259. </td>
  260. </tr>
  261. </table>
  262. </td>
  263. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  264. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  265. <tr>
  266. <td>
  267. <div id="D3" tabindex="0" class="D3_position" role="button">
  268. <span id="D3_status" class="D_status_css">D3 status</span>
  269. </div>
  270. </td>
  271. </tr>
  272. </table>
  273. </td>
  274. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  275. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  276. <tr>
  277. <td>
  278. <div id="D4" tabindex="0" class="D4_position" role="button">
  279. <span id="D4_status" class="D_status_css">D4 status</span>
  280. </div>
  281. </td>
  282. </tr>
  283. </table>
  284. </td>
  285. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  286. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  287. <tr>
  288. <td>
  289. <div id="D5" tabindex="0" class="D5_position" role="button">
  290. <span id="D5_status" class="D_status_css">D5 status</span>
  291. </div>
  292. </td>
  293. </tr>
  294. </table>
  295. </td>
  296. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  297. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  298. <tr>
  299. <td>
  300. <div id="D6" tabindex="0" class="D6_position" role="button">
  301. <span id="D6_status" class="D_status_css">D6 status</span>
  302. </div>
  303. </td>
  304. </tr>
  305. </table>
  306. </td>
  307. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  308. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  309. <tr>
  310. <td>
  311. <div id="DO1" tabindex="0" class="DO1_position" role="button">
  312. <span id="DO1_status" class="D_status_css">DO1 status</span>
  313. </div>
  314. </td>
  315. </tr>
  316. </table>
  317. </td>
  318. </tr>
  319. <tr>
  320. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  321. <div id="DI1_status_dot" style=" height: 20px; background-color: black;"></div>
  322. </td>
  323. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  324. <div id="D1_status_dot" style=" height: 20px; background-color: black;"></div>
  325. </td>
  326. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  327. <div id="D2_status_dot" style=" height: 20px; background-color: black;"></div>
  328. </td>
  329. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  330. <div id="D3_status_dot" style=" height: 20px; background-color: black;"></div>
  331. </td>
  332. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  333. <div id="D4_status_dot" style="height: 20px; background-color: black;"></div>
  334. </td>
  335. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  336. <div id="D5_status_dot" style="height: 20px; background-color: black;"></div>
  337. </td>
  338. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  339. <div id="D6_status_dot" style="height: 20px; background-color: black;"></div>
  340. </td>
  341. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  342. <div id="DO1_status_dot" style="height: 20px; background-color: black;"></div>
  343. </td>
  344. </tr>
  345. <tr>
  346. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  347. 入料儲豆槽
  348. </td>
  349. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  350. 乾燥槽
  351. </td>
  352. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  353. 乾燥槽
  354. </td>
  355. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  356. 乾燥槽
  357. </td>
  358. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  359. 乾燥槽
  360. </td>
  361. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  362. 乾燥槽
  363. </td>
  364. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  365. 乾燥槽
  366. </td>
  367. <td style="border: lightsteelblue 1px solid;" width="12.5%">
  368. 出料儲豆槽
  369. </td>
  370. </tr>
  371. <tr>
  372. <td style="border: lightsteelblue 1px solid;">
  373. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  374. <tr>
  375. <td>
  376. <div id="DI2" tabindex="0" class="DI2_position" role="button">
  377. <span id="DI2_status" class="D_status_css">DI2 status</span>
  378. <!-- D1 狀態點點-->
  379. </div>
  380. </td>
  381. </tr>
  382. </table>
  383. </td>
  384. <td style="border: lightsteelblue 1px solid;">
  385. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  386. <tr>
  387. <td>
  388. <div id="D7" tabindex="0" class="D7_position" role="button">
  389. <span id="D7_status" class="D_status_css">D7 status</span>
  390. </div>
  391. </td>
  392. </tr>
  393. </table>
  394. </td>
  395. <td style="border: lightsteelblue 1px solid;">
  396. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  397. <tr>
  398. <td>
  399. <div id="D8" tabindex="0" class="D8_position" role="button">
  400. <span id="D8_status" class="D_status_css">D8 status</span>
  401. </div>
  402. </td>
  403. </tr>
  404. </table>
  405. </td>
  406. <td style="border: lightsteelblue 1px solid;">
  407. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  408. <tr>
  409. <td>
  410. <div id="D9" tabindex="0" class="D9_position" role="button">
  411. <span id="D9_status" class="D_status_css">D9 status</span>
  412. </div>
  413. </td>
  414. </tr>
  415. </table>
  416. </td>
  417. <td style="border: lightsteelblue 1px solid;">
  418. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  419. <tr>
  420. <td>
  421. <div id="D10" tabindex="0" class="D10_position" role="button">
  422. <span id="D10_status" class="D_status_css">D10 status</span>
  423. </div>
  424. </td>
  425. </tr>
  426. </table>
  427. </td>
  428. <td style="border: lightsteelblue 1px solid;">
  429. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  430. <tr>
  431. <td>
  432. <div id="D11" tabindex="0" class="D11_position" role="button">
  433. <span id="D11_status" class="D_status_css">D11 status</span>
  434. </div>
  435. </td>
  436. </tr>
  437. </table>
  438. </td>
  439. <td style="border: lightsteelblue 1px solid;">
  440. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  441. <tr>
  442. <td>
  443. <div id="D12" tabindex="0" class="D12_position" role="button">
  444. <span id="D12_status" class="D_status_css">D12 status</span>
  445. </div>
  446. </td>
  447. </tr>
  448. </table>
  449. </td>
  450. <td style="border: lightsteelblue 1px solid;">
  451. <table style="border: 0px plum solid; margin-right: auto; margin-left: auto; text-align: center;" cellpadding="5">
  452. <tr>
  453. <td>
  454. <div id="DO2" tabindex="0" class="DO2_position" role="button">
  455. <span id="DO2_status" class="D_status_css">DO2 status</span>
  456. </div>
  457. </td>
  458. </tr>
  459. </table>
  460. </td>
  461. </tr>
  462. <tr>
  463. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  464. <div id="DI2_status_dot" style=" height: 20px; background-color: black;"></div>
  465. </td>
  466. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  467. <div id="D7_status_dot" style=" height: 20px; background-color: black;"></div>
  468. </td>
  469. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  470. <div id="D8_status_dot" style=" height: 20px; background-color: black;"></div>
  471. </td>
  472. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  473. <div id="D9_status_dot" style=" height: 20px; background-color: black;"></div>
  474. </td>
  475. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  476. <div id="D10_status_dot" style="height: 20px; background-color: black;"></div>
  477. </td>
  478. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  479. <div id="D11_status_dot" style="height: 20px; background-color: black;"></div>
  480. </td>
  481. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  482. <div id="D12_status_dot" style="height: 20px; background-color: black;"></div>
  483. </td>
  484. <td width="12.5%" style="border: lightsteelblue 1px solid;">
  485. <div id="DO2_status_dot" style="height: 20px; background-color: black;"></div>
  486. </td>
  487. </tr>
  488. </table>
  489. </div>
  490. <!-- 發酵貨櫃 致動器狀態 感測器數值 -->
  491. <div style="text-align: center;">
  492. <table style="border: 3px lightsteelblue solid; margin-right: auto; margin-left: auto; text-align: center; margin-top: 5px;" cellpadding="5" border="1">
  493. <tr>
  494. <td width="9%" style="border: lightsteelblue 1px solid;">
  495. 桶槽<br>真空吸料機
  496. </td>
  497. <td width="9%" style="border: lightsteelblue 1px solid;">
  498. 入料<br>三通閥
  499. </td>
  500. <td width="9%" style="border: lightsteelblue 1px solid;">
  501. 蝴蝶閥
  502. </td>
  503. <td width="9%" style="border: lightsteelblue 1px solid;">
  504. 保溫夾層進水<br>電磁閥
  505. </td>
  506. <td width="9%" style="border: lightsteelblue 1px solid;">
  507. 桶內消毒<br>電磁閥
  508. </td>
  509. <td width="9%" style="border: lightsteelblue 1px solid;">
  510. 排水廢水<br>電磁閥
  511. </td>
  512. <td width="9%" style="border: lightsteelblue 1px solid;">
  513. 馬達
  514. </td>
  515. <td width="9%" style="border: lightsteelblue 1px solid;">
  516. 乾燥<br>真空機
  517. </td>
  518. <td width="9%" style="border: lightsteelblue 1px solid;">
  519. 加熱器<br>1
  520. </td>
  521. <td width="9%" style="border: lightsteelblue 1px solid;">
  522. 加熱器<br>2
  523. </td>
  524. <td width="9%" style="border: lightsteelblue 1px solid;">
  525. 警示燈
  526. </td>
  527. </tr>
  528. <tr>
  529. <td style="border: lightsteelblue 1px solid;">
  530. <div id="actuator_0_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  531. </td>
  532. <td style="border: lightsteelblue 1px solid;">
  533. <div id="actuator_1_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  534. </td>
  535. <td style="border: lightsteelblue 1px solid;">
  536. <div id="actuator_2_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  537. </td>
  538. <td style="border: lightsteelblue 1px solid;">
  539. <div id="actuator_3_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  540. </td>
  541. <td style="border: lightsteelblue 1px solid;">
  542. <div id="actuator_4_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  543. </td>
  544. <td style="border: lightsteelblue 1px solid;">
  545. <div id="actuator_5_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  546. </td>
  547. <td style="border: lightsteelblue 1px solid;">
  548. <div id="actuator_6_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  549. </td>
  550. <td style="border: lightsteelblue 1px solid;">
  551. <div id="actuator_7_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  552. </td>
  553. <td style="border: lightsteelblue 1px solid;">
  554. <div id="actuator_8_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  555. </td>
  556. <td style="border: lightsteelblue 1px solid;">
  557. <div id="actuator_9_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  558. </td>
  559. <td style="border: lightsteelblue 1px solid;">
  560. <div id="actuator_10_status" style="margin:0 auto; height: 20px; background-color: lightgray;"></div>
  561. </td>
  562. </tr>
  563. </table>
  564. <table style="border: 3px lightsteelblue solid; margin-right: auto; margin-left: auto; text-align: center; margin-top: 5px;" cellpadding="5" border="1">
  565. <tr>
  566. <td style="border: lightsteelblue 1px solid;">
  567. 生豆<br>高度
  568. </td>
  569. <td style="border: lightsteelblue 1px solid;">
  570. 溫度
  571. </td>
  572. <td style="border: lightsteelblue 1px solid;">
  573. 濕度
  574. </td>
  575. <td style="border: lightsteelblue 1px solid;">
  576. 生豆<br>溫度
  577. </td>
  578. <td style="border: lightsteelblue 1px solid;">
  579. 生豆<br>濕度
  580. </td>
  581. <td style="border: lightsteelblue 1px solid;">
  582. 生豆<br>導電度
  583. </td>
  584. <td style="border: lightsteelblue 1px solid;">
  585. 大氣壓力
  586. </td>
  587. <td style="border: lightsteelblue 1px solid;">
  588. 馬達<br>編碼器
  589. </td>
  590. <td style="border: lightsteelblue 1px solid;">
  591. 蝴蝶閥<br>編碼器
  592. </td>
  593. <td style="border: lightsteelblue 1px solid;">
  594. 保溫夾層<br>水位
  595. </td>
  596. </tr>
  597. <tr>
  598. <td style="border: lightsteelblue 1px solid;">
  599. <span id="sensor_1"></span>
  600. </td>
  601. <td style="border: lightsteelblue 1px solid;">
  602. <span id="sensor_2"></span>
  603. </td>
  604. <td style="border: lightsteelblue 1px solid;">
  605. <span id="sensor_3"></span>
  606. </td>
  607. <td style="border: lightsteelblue 1px solid;">
  608. <span id="sensor_4"></span>
  609. </td>
  610. <td style="border: lightsteelblue 1px solid;">
  611. <span id="sensor_5"></span>
  612. </td>
  613. <td style="border: lightsteelblue 1px solid;">
  614. <span id="sensor_6"></span>
  615. </td>
  616. <td style="border: lightsteelblue 1px solid;">
  617. <span id="sensor_7"></span>
  618. </td>
  619. <td style="border: lightsteelblue 1px solid;">
  620. <span id="sensor_8"></span>
  621. </td>
  622. <td style="border: lightsteelblue 1px solid;">
  623. <span id="sensor_9"></span>
  624. </td>
  625. <td style="border: lightsteelblue 1px solid;">
  626. <span id="sensor_10"></span>
  627. </td>
  628. </tr>
  629. </table>
  630. <table style="border: 3px lightsteelblue solid; margin-right: auto; margin-left: auto; text-align: center; margin-top: 5px; line-height: 28px;" cellpadding="5" border="1">
  631. <tr>
  632. <td style="border: lightsteelblue 1px solid;">
  633. 桶槽<br>
  634. 參數設定
  635. </td>
  636. </tr>
  637. <tr>
  638. <td style="padding: 10px; text-align: left; vertical-align: text-top;">
  639. 生豆高度
  640. <input name="Dry_Tank_bean_height" type="text" class="input-text" value="5">公分<br>
  641. 吸放料時間
  642. <input name="Dry_Tank_vacuum_time" type="text" class="input-text" value="10">秒,
  643. 馬達轉速
  644. <input name="Dry_Tank_motor_rpm" type="text" class="input-text" value="30">rpm<br>
  645. ----- 溫度權重設定 ----------------------------------------------<br>
  646. [SHT11]桶內溫度×權重
  647. <input name="Dry_Tank_TempWeight_SHT11" type="text" class="input-text" value="0.5">
  648. +
  649. [soil]生豆溫度×權重
  650. <input name="Dry_Tank_TempWeight_soil" type="text" class="input-text" value="0.5">
  651. <br>
  652. ----- 乾燥完成條件 (輸入 0 代表不設定) ------------------------<br>
  653. 指定溫度
  654. <input name="Dry_Tank_drying_temp" type="text" class="input-text" value="40">℃<br>
  655. 消毒開啟
  656. <input name="Dry_Tank_Disinfect_time" class="input-text" type="text" value="10">秒
  657. </td>
  658. </tr>
  659. </table>
  660. </div>
  661. </div>
  662. </div>
  663. </div>
  664. </div>
  665. </div>
  666. </div>
  667. </div>
  668. {% endblock %}