edit_config_param.html 38 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Edit Config</title>
  5. <meta charset="utf-8">
  6. <style>
  7. h1 {font-size: 2em;}
  8. h2 {font-size: 1.5em; margin-block-start: 0.0em; margin-block-end: 0.2em;}
  9. h3 {font-size: 1.2em;}
  10. p {font-size: 1em;}
  11. .button {
  12. padding: 5px 20px;
  13. width: 211px;
  14. font-size: 16px;
  15. }
  16. textarea {
  17. font-size: 14px;
  18. }
  19. </style>
  20. </head>
  21. <body style="font-family: arial; padding: 0px 10px;">
  22. <table style="width:100%">
  23. <tr>
  24. <td>
  25. <h2>Config.ini:</h2>
  26. </td>
  27. <td>
  28. <button class="button" id="Edit_Config_Direct" onclick="editConfigDirect()" style="display:none">Edit Config.ini direct</button>
  29. <input type="checkbox" id="ExpertModus_enabled" value="1" onclick = 'UpdateExpertModus()' unchecked><label for="ExpertModus_enabled"> Expertenmodus </label>
  30. </td>
  31. </tr>
  32. </table>
  33. <br>
  34. <div id = "divall" style="display:none">
  35. <table>
  36. <tr>
  37. <th width="20px" style="text-align: left;">
  38. Enable
  39. </th>
  40. <th width="200px" style="text-align: left;">
  41. Parameter
  42. </th>
  43. <th style="text-align: left;">
  44. Value
  45. </th>
  46. <th style="text-align: left;">
  47. Information
  48. </th>
  49. </tr>
  50. <tr>
  51. <td colspan="4" style="padding-left: 20px;"><h4>MakeImage</h4></td>
  52. </tr>
  53. <tr>
  54. <td width="20px" style="padding-left: 40px;">
  55. <input type="checkbox" id="MakeImage_LogImageLocation_enabled" value="1" onclick = 'InvertEnableItem("MakeImage", "LogImageLocation")' unchecked >
  56. </td>
  57. <td width="200px">
  58. <class id="MakeImage_LogImageLocation_text" style="color:black;">LogImageLocation</class>
  59. </td>
  60. <td>
  61. <input type="text" name="name" id="MakeImage_LogImageLocation_value1">
  62. </td>
  63. <td style="font-size: 80%;">
  64. Location to store raw images for logging
  65. </td>
  66. </tr>
  67. <tr>
  68. <td width="20px" style="padding-left: 40px;">
  69. <td"><input type="checkbox" id="MakeImage_LogfileRetentionInDays_enabled" value="1" onclick = 'InvertEnableItem("MakeImage", "LogfileRetentionInDays")' unchecked ></td>
  70. </td>
  71. <td>
  72. <class id="MakeImage_LogfileRetentionInDays_text" style="color:black;">LogfileRetentionInDays</class>
  73. </td>
  74. <td>
  75. <input type="number" id="MakeImage_LogfileRetentionInDays_value1" size="13" min="0" step="1">
  76. </td>
  77. <td style="font-size: 80%;">
  78. Time to keep the raw image (in days -"0" = forever)
  79. </td>
  80. </tr>
  81. <tr class="expert" id="ex1">
  82. <td width="20px" style="padding-left: 40px;">
  83. </td>
  84. <td>
  85. <class id="MakeImage_WaitBeforeTakingPicture_text" style="color:black;">WaitBeforeTakingPicture</class>
  86. </td>
  87. <td>
  88. <input type="number" id="MakeImage_WaitBeforeTakingPicture_value1" size="13" min="0" step="any">
  89. </td>
  90. <td style="font-size: 80%;">
  91. Wait time between illumination switch on and take the picture (in seconds)
  92. </td>
  93. </tr>
  94. <tr class="expert" id="ex2">
  95. <td width="20px" style="padding-left: 40px;">
  96. </td>
  97. <td>
  98. <class id="MakeImage_ImageQuality_text" style="color:black;">ImageQuality</class>
  99. </td>
  100. <td>
  101. <input type="number" id="MakeImage_ImageQuality_value1" size="13" min="0" max="63">
  102. </td>
  103. <td style="font-size: 80%;">
  104. Quality index for picture (default = "5" - "0" high ... "63" low)
  105. </td>
  106. </tr>
  107. <tr class="expert" id="ex3">
  108. <td width="20px" style="padding-left: 40px;">
  109. </td>
  110. <td>
  111. <class id="MakeImage_ImageSize_text" style="color:black;">ImageSize</class>
  112. </td>
  113. <td>
  114. <select id="MakeImage_ImageSize_value1">
  115. <option value="0" selected>VGA</option>
  116. <option value="1" >QVGA</option>
  117. </select>
  118. </td>
  119. <td style="font-size: 80%;">
  120. Picture size camera (default = "VGA")
  121. </td>
  122. </tr>
  123. <tr class="expert" id="Brightness_ex3">
  124. <td width="20px" style="padding-left: 40px;">
  125. </td>
  126. <td>
  127. <class id="MakeImage_Brightness_text" style="color:black;">Brightness</class>
  128. </td>
  129. <td>
  130. <input type="number" id="MakeImage_Brightness_value1" size="13" min="-2" max="2">
  131. </td>
  132. <td style="font-size: 80%;">
  133. Image Brightness (-2 .. 2 - default = "0")
  134. </td>
  135. </tr>
  136. <tr class="expert" id="MakeImage_FixedExposure_ex10">
  137. <td width="20px" style="padding-left: 40px;">
  138. </td>
  139. <td width="200px">
  140. <class id="MakeImage_FixedExposure_text" style="color:black;">FixedExposure</class>
  141. </td>
  142. <td>
  143. <select id="MakeImage_FixedExposure_value1">
  144. <option value="0" selected>true</option>
  145. <option value="1" >false</option>
  146. </select>
  147. </td>
  148. <td style="font-size: 80%;">
  149. Fixes the illumination setting of camera at the startup and uses this later --> individual round is faster
  150. </td>
  151. </tr>
  152. <!--
  153. <tr class="expert" id="Contrast_ex3">
  154. <td width="20px" style="padding-left: 40px;">
  155. </td>
  156. <td>
  157. <class id="MakeImage_Contrast_text" style="color:black;">Contrast</class>
  158. </td>
  159. <td>
  160. <input type="number" id="MakeImage_Contrast_value1" size="13" min="-2" max="2">
  161. </td>
  162. <td style="font-size: 80%;">
  163. Image Contrast (-2 .. 2 - default = "0")
  164. </td>
  165. </tr>
  166. <tr class="expert" id="Saturation_ex3">
  167. <td width="20px" style="padding-left: 40px;">
  168. </td>
  169. <td>
  170. <class id="MakeImage_Saturation_text" style="color:black;">Saturation</class>
  171. </td>
  172. <td>
  173. <input type="number" id="MakeImage_Saturation_value1" size="13" min="-2" max="2">
  174. </td>
  175. <td style="font-size: 80%;">
  176. Image Saturation (-2 .. 2 - default = "0")
  177. </td>
  178. </tr>
  179. -->
  180. <tr class="expert" id="ex4">
  181. <td colspan="4" style="padding-left: 20px;"><h4>Alignment</h4></td>
  182. </tr>
  183. <tr class="expert" id="ex6">
  184. <td width="20px" style="padding-left: 40px;">
  185. </td>
  186. <td width="200px">
  187. <class id="Alignment_SearchFieldX_text" style="color:black;">SearchFieldX</class>
  188. </td>
  189. <td>
  190. <input type="number" name="name" id="Alignment_SearchFieldX_value1" size="13" min="1" step="1">
  191. </td>
  192. <td style="font-size: 80%;">
  193. x size (width) in which the reference is searched (default = "20")
  194. </td>
  195. </tr>
  196. <tr class="expert" id="ex8">
  197. <td width="20px" style="padding-left: 40px;">
  198. </td>
  199. <td>
  200. <class id="Alignment_SearchFieldY_text" style="color:black;">SearchFieldY</class>
  201. </td>
  202. <td>
  203. <input type="number" name="name" id="Alignment_SearchFieldY_value1" size="13" min="1">
  204. </td>
  205. <td style="font-size: 80%;">
  206. y size (height) in which the reference is searched (default = "20")
  207. </td>
  208. </tr>
  209. <tr class="expert" id="AlignmentAlgo_ex8">
  210. <td width="20px" style="padding-left: 40px;">
  211. <input type="checkbox" id="Alignment_AlignmentAlgo_enabled" value="1" onclick = 'InvertEnableItem("Alignment", "AlignmentAlgo")' unchecked >
  212. </td>
  213. <td>
  214. <class id="Alignment_AlignmentAlgo_text" style="color:black;">AlignmentAlgo</class>
  215. </td>
  216. <td>
  217. <select id="Alignment_AlignmentAlgo_value1">
  218. <option value="0" selected>Default</option>
  219. <option value="1" >HighAccurity</option>
  220. <option value="2" >Fast</option>
  221. </select>
  222. </td>
  223. <td style="font-size: 80%;">
  224. "Default" = use only R-Channel, "HighAccurity" = use all Channels (RGB, 3x slower), <br> "Fast" (First time RGB, then only check if image is shifted)
  225. </td>
  226. </tr>
  227. <tr id="Category_Digits_ex4">
  228. <td colspan="4" style="padding-left: 20px;">
  229. <h4><input type="checkbox" id="Category_Digits_enabled" value="1" onclick = 'UpdateAfterCategoryCheck()' unchecked >Digits</h4></td>
  230. </tr>
  231. <tr>
  232. <td width="20px" style="padding-left: 40px;">
  233. </td>
  234. <td width="200px">
  235. <class id="Digits_Model_text" style="color:black;">Model</class>
  236. </td>
  237. <td>
  238. <input type="text" id="Digits_Model_value1">
  239. </td>
  240. <td style="font-size: 80%;">
  241. path to CNN model file for image recognition
  242. </td>
  243. </tr>
  244. <tr>
  245. <td width="20px" style="padding-left: 40px;">
  246. <input type="checkbox" id="Digits_LogImageLocation_enabled" value="1" onclick = 'InvertEnableItem("Digits", "LogImageLocation")' unchecked >
  247. </td>
  248. <td>
  249. <class id="Digits_LogImageLocation_text" style="color:black;">LogImageLocation</class>
  250. </td>
  251. <td>
  252. <input type="text" name="name" id="Digits_LogImageLocation_value1">
  253. </td>
  254. <td style="font-size: 80%;">
  255. Location to store separated digits for logging
  256. </td>
  257. </tr>
  258. <tr>
  259. <td width="20px" style="padding-left: 40px;">
  260. <td"><input type="checkbox" id="Digits_LogfileRetentionInDays_enabled" value="1" onclick = 'InvertEnableItem("Digits", "LogfileRetentionInDays")' unchecked ></td>
  261. </td>
  262. <td>
  263. <class id="Digits_LogfileRetentionInDays_text" style="color:black;">LogfileRetentionInDays</class>
  264. </td>
  265. <td>
  266. <input type="number" id="Digits_LogfileRetentionInDays_value1" min="0" step="1">
  267. </td>
  268. <td style="font-size: 80%;">
  269. Time to keep the separated digit images (in days -"0" = forever)
  270. </td>
  271. </tr>
  272. <tr class="expert" id="ex9">
  273. <td width="20px" style="padding-left: 40px;">
  274. </td>
  275. <td>
  276. <class id="Digits_ModelInputSize_text" style="color:black;">ModelInputSize</class>
  277. </td>
  278. <td>
  279. x: <input type="number" id="Digits_ModelInputSize_value1" style="width: 30px;" min="1" step="1">
  280. y: <input type="number" id="Digits_ModelInputSize_value2" style="width: 30px;" min="1" step="1">
  281. </td>
  282. <td style="font-size: 80%;">
  283. Size of the input image for the CNN model
  284. </td>
  285. </tr>
  286. <tr class="expert" id="ex4">
  287. <td colspan="4" style="padding-left: 20px;">
  288. <h4><input type="checkbox" id="Category_Analog_enabled" value="1" onclick = 'UpdateAfterCategoryCheck()' unchecked > Analog</h4></td>
  289. </tr>
  290. <tr>
  291. <td width="20px" style="padding-left: 40px;"> </td>
  292. <td width="200px"> <class id="Analog_Model_text" style="color:black;">Model</class> </td>
  293. <td> <input type="text" id="Analog_Model_value1"> </td>
  294. <td style="font-size: 80%;"> path to CNN model file for image recognition</td>
  295. </tr>
  296. <tr>
  297. <td width="20px" style="padding-left: 40px;">
  298. <input type="checkbox" id="Analog_LogImageLocation_enabled" value="1" onclick = 'InvertEnableItem("Analog", "LogImageLocation")' unchecked >
  299. </td>
  300. <td> <class id="Analog_LogImageLocation_text" style="color:black;">LogImageLocation</class> </td>
  301. <td> <input type="text" name="name" id="Analog_LogImageLocation_value1"> </td>
  302. <td style="font-size: 80%;"> Location to store separated digits for logging </td>
  303. </tr>
  304. <tr>
  305. <td width="20px" style="padding-left: 40px;">
  306. <td"><input type="checkbox" id="Analog_LogfileRetentionInDays_enabled" value="1" onclick = 'InvertEnableItem("Analog", "LogfileRetentionInDays")' unchecked ></td>
  307. </td>
  308. <td> <class id="Analog_LogfileRetentionInDays_text" style="color:black;">LogfileRetentionInDays</class> </td>
  309. <td> <input type="number" id="Analog_LogfileRetentionInDays_value1" min="0" step="1"> </td>
  310. <td style="font-size: 80%;"> Time to keep the separated digit images (in days -"0" = forever) </td>
  311. </tr>
  312. <tr class="expert" id="Analog_ExtendedResolution_ex10">
  313. <td width="20px" style="padding-left: 40px;">
  314. <input type="checkbox" id="Analog_ExtendedResolution_enabled" value="1" onclick = 'InvertEnableItem("Analog", "ExtendedResolution")' unchecked >
  315. </td>
  316. <td width="200px">
  317. <class id="Analog_ExtendedResolution_text" style="color:black;">ExtendedResolution</class>
  318. </td>
  319. <td>
  320. <select id="Analog_ExtendedResolution_value1">
  321. <option value="0" selected>true</option>
  322. <option value="1" >false</option>
  323. </select>
  324. </td>
  325. <td style="font-size: 80%;">
  326. Enable to use the after point resolution for the last analog counter
  327. </td>
  328. </tr>
  329. ExtendedResolution
  330. <tr class="expert" id="ex10">
  331. <td width="20px" style="padding-left: 40px;"> </td>
  332. <td> <class id="Analog_ModelInputSize_text" style="color:black;">ModelInputSize</class> </td>
  333. <td>
  334. x: <input type="number" id="Analog_ModelInputSize_value1" style="width: 30px;" min="1" step="1">
  335. y: <input type="number" id="Analog_ModelInputSize_value2" style="width: 30px;" min="1" step="1">
  336. </td>
  337. <td style="font-size: 80%;"> Size of the input image for the CNN model </td>
  338. </tr>
  339. <tr>
  340. <td colspan="4" style="padding-left: 20px;"><h4>PostProcessing</h4></td>
  341. </tr>
  342. <tr>
  343. <td width="20px" style="padding-left: 40px;">
  344. <input type="checkbox" id="PostProcessing_PreValueUse_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "PreValueUse")' unchecked >
  345. </td>
  346. <td width="200px">
  347. <class id="PostProcessing_PreValueUse_text" style="color:black;">PreValueUse</class>
  348. </td>
  349. <td>
  350. <select id="PostProcessing_PreValueUse_value1">
  351. <option value="0" selected>true</option>
  352. <option value="1" >false</option>
  353. </select>
  354. </td>
  355. <td style="font-size: 80%;">
  356. Enable to use the previous read value for consistency checks - also on reboots
  357. </td>
  358. </tr>
  359. <tr class="expert" id="ex11">
  360. <td width="20px" style="padding-left: 40px;">
  361. <input type="checkbox" id="PostProcessing_PreValueAgeStartup_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "PreValueAgeStartup")' unchecked >
  362. </td>
  363. <td width="200px">
  364. <class id="PostProcessing_PreValueAgeStartup_text" style="color:black;">PreValueAgeStartup</class>
  365. </td>
  366. <td>
  367. <input type="number" id="PostProcessing_PreValueAgeStartup_value1" size="13" min="0">
  368. </td>
  369. <td style="font-size: 80%;">
  370. Time (in minutes), how long a previous read value is valid after reboot (default = 720 min)
  371. </td>
  372. </tr>
  373. <tr>
  374. <td width="20px" style="padding-left: 40px;">
  375. <input type="checkbox" id="PostProcessing_AllowNegativeRates_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "AllowNegativeRates")' unchecked >
  376. </td>
  377. <td width="200px">
  378. <class id="PostProcessing_AllowNegativeRates_text" style="color:black;">AllowNegativeRates</class>
  379. </td>
  380. <td>
  381. <select id="PostProcessing_AllowNegativeRates_value1">
  382. <option value="0" selected>true</option>
  383. <option value="1" >false</option>
  384. </select>
  385. </td>
  386. <td style="font-size: 80%;">
  387. Set on "false" to ensure, that only positive changes are accepted (typically for counter)
  388. </td>
  389. </tr>
  390. <tr>
  391. <td width="20px" style="padding-left: 40px;">
  392. <input type="checkbox" id="PostProcessing_MaxRateValue_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "MaxRateValue")' unchecked >
  393. </td>
  394. <td width="200px">
  395. <class id="PostProcessing_MaxRateValue_text" style="color:black;">MaxRateValue</class>
  396. </td>
  397. <td>
  398. <input type="number" id="PostProcessing_MaxRateValue_value1" size="13" min="0" step="any">
  399. </td>
  400. <td style="font-size: 80%;">
  401. Maximum change of reading from one to the next readout
  402. </td>
  403. </tr>
  404. <tr class="expert" id="ex12">
  405. <td width="20px" style="padding-left: 40px;">
  406. <input type="checkbox" id="PostProcessing_ErrorMessage_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "ErrorMessage")' unchecked >
  407. </td>
  408. <td width="200px">
  409. <class id="PostProcessing_ErrorMessage_text" style="color:black;">ErrorMessage</class>
  410. </td>
  411. <td>
  412. <select id="PostProcessing_ErrorMessage_value1">
  413. <option value="0" selected>true</option>
  414. <option value="1" >false</option>
  415. </select>
  416. </td>
  417. <td style="font-size: 80%;">
  418. Do not show error message in return value - in error case, the last valid number will be send out
  419. </td>
  420. </tr>
  421. <tr>
  422. <td width="20px" style="padding-left: 40px;">
  423. <input type="checkbox" id="PostProcessing_CheckDigitIncreaseConsistency_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "CheckDigitIncreaseConsistency")' unchecked >
  424. </td>
  425. <td width="200px">
  426. <class id="PostProcessing_CheckDigitIncreaseConsistency_text" style="color:black;">CheckDigitIncreaseConsistency</class>
  427. </td>
  428. <td>
  429. <select id="PostProcessing_CheckDigitIncreaseConsistency_value1">
  430. <option value="0" selected>true</option>
  431. <option value="1" >false</option>
  432. </select>
  433. </td>
  434. <td style="font-size: 80%;">
  435. Activate to enalbe additional consistency check - especially zero crossing check between digits
  436. </td>
  437. </tr>
  438. <tr>
  439. <td style="padding-left: 40px;" colspan="4">
  440. <br>
  441. <b>Postprocessing Individual Paramters:
  442. <select id="Numbers_value1" onchange="numberChanged()">
  443. <option value="0" selected>default</option>
  444. <option value="1" >NT</option>
  445. <option value="2" >HT</option>
  446. </select></b>
  447. </td>
  448. </tr>
  449. <tr>
  450. <td width="20px" style="padding-left: 40px;">
  451. <input type="checkbox" id="PostProcessing_DecimalShift_enabled" value="1" onclick = 'InvertEnableItem("PostProcessing", "DecimalShift")' unchecked >
  452. </td>
  453. <td width="200px">
  454. <class id="PostProcessing_DecimalShift_text" style="color:black;">DecimalShift</class>
  455. </td>
  456. <td>
  457. <input type="number" id="PostProcessing_DecimalShift_value1" step="1">
  458. </td>
  459. <td style="font-size: 80%;">
  460. shift the digit separator within the digital digits (positiv and negativ)
  461. </td>
  462. </tr>
  463. <tr>
  464. <td colspan="4" style="padding-left: 20px;"><h4><input type="checkbox" id="Category_MQTT_enabled" value="1" onclick = 'UpdateAfterCategoryCheck()' unchecked > MQTT</h4></td>
  465. </tr>
  466. <tr>
  467. <td width="20px" style="padding-left: 40px;">
  468. <input type="checkbox" id="MQTT_Uri_enabled" value="1" onclick = 'InvertEnableItem("MQTT", "Uri")' unchecked >
  469. </td>
  470. <td width="200px">
  471. <class id="MQTT_Uri_text" style="color:black;">Uri</class>
  472. </td>
  473. <td>
  474. <input type="text" id="MQTT_Uri_value1">
  475. </td>
  476. <td style="font-size: 80%;">
  477. URI to the MQTT broker including port e.g.: mqtt://IP-Address:Port
  478. </td>
  479. </tr>
  480. <tr>
  481. <td width="20px" style="padding-left: 40px;">
  482. <input type="checkbox" id="MQTT_MainTopic_enabled" value="1" onclick = 'InvertEnableItem("MQTT", "MainTopic")' unchecked >
  483. </td>
  484. <td width="200px">
  485. <class id="MQTT_MainTopic_text" style="color:black;">MainTopic</class>
  486. </td>
  487. <td>
  488. <input type="text" id="MQTT_MainTopic_value1">
  489. </td>
  490. <td style="font-size: 80%;">
  491. MQTT main topic, under which the counters are published. The single value will be published with the following key: MAINTOPIC/VALUE_NAME/PARAMTER <br>
  492. where parameters are: value, rate, timestamp, error<br>
  493. The general connection status can be found in MAINTOPiC"/CONNECTION
  494. </td>
  495. </tr>
  496. <tr>
  497. <td width="20px" style="padding-left: 40px;">
  498. <input type="checkbox" id="MQTT_ClientID_enabled" value="1" onclick = 'InvertEnableItem("MQTT", "ClientID")' unchecked >
  499. </td>
  500. <td width="200px">
  501. <class id="MQTT_ClientID_text" style="color:black;">ClientID</class>
  502. </td>
  503. <td>
  504. <input type="text" id="MQTT_ClientID_value1">
  505. </td>
  506. <td style="font-size: 80%;">
  507. ClientID to connect to the MQTT broker
  508. </td>
  509. </tr>
  510. <tr>
  511. <td width="20px" style="padding-left: 40px;">
  512. <input type="checkbox" id="MQTT_user_enabled" value="1" onclick = 'InvertEnableItem("MQTT", "user")' unchecked >
  513. </td>
  514. <td width="200px">
  515. <class id="MQTT_user_text" style="color:black;">user</class>
  516. </td>
  517. <td>
  518. <input type="text" id="MQTT_user_value1">
  519. </td>
  520. <td style="font-size: 80%;">
  521. user for MQTT authentication
  522. </td>
  523. </tr>
  524. <tr>
  525. <td width="20px" style="padding-left: 40px;">
  526. <input type="checkbox" id="MQTT_password_enabled" value="1" onclick = 'InvertEnableItem("MQTT", "password")' unchecked >
  527. </td>
  528. <td width="200px">
  529. <class id="MQTT_password_text" style="color:black;">password</class>
  530. </td>
  531. <td>
  532. <input type="text" id="MQTT_password_value1">
  533. </td>
  534. <td style="font-size: 80%;">
  535. password for MQTT authentication
  536. </td>
  537. </tr>
  538. <tr>
  539. <td colspan="4" style="padding-left: 20px;"><h4>AutoTimer</h4></td>
  540. </tr>
  541. <tr class="expert" id="ex13">
  542. <td width="20px" style="padding-left: 40px;">
  543. </td>
  544. <td width="200px">
  545. <class id="AutoTimer_AutoStart_text" style="color:black;">AutoStart</class>
  546. </td>
  547. <td>
  548. <select id="AutoTimer_AutoStart_value1">
  549. <option value="0" selected>true</option>
  550. <option value="1" >false</option>
  551. </select>
  552. </td>
  553. <td style="font-size: 80%;">
  554. Start the image recognition immediatly after power up. false is basically for debugging.
  555. </td>
  556. </tr>
  557. <tr>
  558. <td width="20px" style="padding-left: 40px;">
  559. </td>
  560. <td width="200px">
  561. <class id="AutoTimer_Intervall_text" style="color:black;">Intervall</class>
  562. </td>
  563. <td>
  564. <input type="number" id="AutoTimer_Intervall_value1" size="13" min="3" step="any">
  565. </td>
  566. <td style="font-size: 80%;">
  567. Intervall in which the counter is read (in minutes). Number must be greater than 3 minutes.
  568. </td>
  569. </tr>
  570. <tr>
  571. <td colspan="4" style="padding-left: 20px;"><h4>Debug</h4></td>
  572. </tr>
  573. <tr>
  574. <td width="20px" style="padding-left: 40px;">
  575. <input type="checkbox" id="Debug_Logfile_enabled" value="1" onclick = 'InvertEnableItem("Debug", "Logfile")' unchecked >
  576. </td>
  577. <td width="200px">
  578. <class id="Debug_Logfile_text" style="color:black;">Logfile</class>
  579. </td>
  580. <td>
  581. <select id="Debug_Logfile_value1">
  582. <option value="0" selected>true</option>
  583. <option value="1" >false</option>
  584. </select>
  585. </td>
  586. <td style="font-size: 80%;">
  587. Turn on/off the extended logging
  588. </td>
  589. </tr>
  590. <tr>
  591. <td width="20px" style="padding-left: 40px;">
  592. <td"><input type="checkbox" id="Debug_LogfileRetentionInDays_enabled" value="1" onclick = 'InvertEnableItem("Debug", "LogfileRetentionInDays")' unchecked ></td>
  593. </td>
  594. <td>
  595. <class id="Debug_LogfileRetentionInDays_text" style="color:black;">LogfileRetentionInDays</class>
  596. </td>
  597. <td>
  598. <input type="number" id="Debug_LogfileRetentionInDays_value1" size="13" min="0" step="1">
  599. </td>
  600. <td style="font-size: 80%;">
  601. Time to keep the log files (in days - "0" = forever)
  602. </td>
  603. </tr>
  604. <tr>
  605. <td colspan="4" style="padding-left: 20px;"><h4>System</h4></td>
  606. </tr>
  607. <tr>
  608. <td width="20px" style="padding-left: 40px;">
  609. <td"><input type="checkbox" id="System_TimeZone_enabled" value="1" onclick = 'InvertEnableItem("System", "TimeZone")' unchecked ></td>
  610. </td>
  611. <td>
  612. <class id="System_TimeZone_text" style="color:black;">TimeZone</class>
  613. </td>
  614. <td>
  615. <input type="text" id="System_TimeZone_value1">
  616. </td>
  617. <td style="font-size: 80%;">
  618. Time zone in POSIX syntax (Europe/Berlin = "CET-1CEST,M3.5.0,M10.5.0/3" - incl. daylight saving)
  619. </td>
  620. </tr>
  621. <tr class="expert" id="ex16">
  622. <td width="20px" style="padding-left: 40px;">
  623. <td"><input type="checkbox" id="System_TimeServer_enabled" value="1" onclick = 'InvertEnableItem("System", "TimeServer")' unchecked ></td>
  624. </td>
  625. <td>
  626. <class id="System_TimeServer_text" style="color:black;">TimeServer</class>
  627. </td>
  628. <td>
  629. <input type="text" id="System_TimeServer_value1">
  630. </td>
  631. <td style="font-size: 80%;">
  632. Time server to synchronize system time (default: "pool.ntp.org" - used if nothing is specified)
  633. </td>
  634. </tr>
  635. <tr class="expert" id="System_Hostname">
  636. <td width="20px" style="padding-left: 40px;">
  637. <td"><input type="checkbox" id="System_Hostname_enabled" value="1" onclick = 'InvertEnableItem("System", "Hostname")' unchecked ></td>
  638. </td>
  639. <td>
  640. <class id="System_Hostname_text" style="color:black;">Hostname</class>
  641. </td>
  642. <td>
  643. <input type="text" id="System_Hostname_value1">
  644. </td>
  645. <td style="font-size: 80%;">
  646. Hostname for server - will be transfered to wlan.ini at next startup)
  647. </td>
  648. </tr>
  649. </table>
  650. <p>
  651. <button class="button" onclick="saveTextAsFile()">Update Config.ini</button>
  652. </p>
  653. <p>
  654. </p>
  655. <div id="doreboot">
  656. <p>
  657. <button class="button" id="Edit_Config_Direct" onclick="editConfigDirect()" style="display:none">Edit Config.ini direct</button>
  658. <button class="button" id="reboot" type="button" onclick="doReboot()">Reboot to activate updates</button>
  659. </p>
  660. </div>
  661. </div>
  662. <script type="text/javascript" src="./gethost.js"></script>
  663. <script type="text/javascript" src="./readconfigcommon.js"></script>
  664. <script type="text/javascript" src="./readconfigparam.js"></script>
  665. <script type="text/javascript">
  666. var canvas = document.getElementById('canvas'),
  667. basepath = "http://192.168.178.22";
  668. param;
  669. category;
  670. NUNBERSAkt = -1;
  671. NUMBERS;
  672. function LoadConfigNeu() {
  673. var isInitialSetup = getParameterByName('InitialSetup');
  674. if (isInitialSetup === 'true')
  675. {
  676. document.getElementById("reboot").style.display = "none";
  677. }
  678. basepath = getbasepath();
  679. if (!loadConfig(basepath)) {
  680. alert("Config.ini could not be loaded!\nPlease reload the page.");
  681. return;
  682. }
  683. // loadConfig(basepath);
  684. ParseConfig();
  685. param = getConfigParameters();
  686. category = getConfigCategory();
  687. InitIndivParameter();
  688. UpdateInput();
  689. UpdateInputIndividual();
  690. UpdateExpertModus();
  691. document.getElementById("divall").style.display = '';
  692. }
  693. function InitIndivParameter()
  694. {
  695. NUMBERS = getNUMBERInfo();
  696. var _index = document.getElementById("Numbers_value1");
  697. while (_index.length)
  698. _index.remove(0);
  699. for (var i = 0; i < NUMBERS.length; ++i){
  700. var option = document.createElement("option");
  701. option.text = NUMBERS[i]["name"];
  702. option.value = i;
  703. _index.add(option);
  704. }
  705. _index.selectedIndex = 0;
  706. }
  707. function getParameterByName(name, url = window.location.href) {
  708. name = name.replace(/[\[\]]/g, '\\$&');
  709. var regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)'),
  710. results = regex.exec(url);
  711. if (!results) return null;
  712. if (!results[2]) return '';
  713. return decodeURIComponent(results[2].replace(/\+/g, ' '));
  714. }
  715. function WriteParameter(_param, _category, _cat, _name, _optional, _select = false, _anzpara = 1, _number = -1){
  716. if (_number > -1)
  717. {
  718. {
  719. if (_optional) {
  720. document.getElementById(_cat+"_"+_name+"_enabled").checked = _param[_cat][_name]["enabled"];
  721. for (var j = 1; j <= _anzpara; ++j)
  722. document.getElementById(_cat+"_"+_name+"_value"+j).disabled = NUMBERS[_number][_cat][_name]["enabled"];
  723. }
  724. document.getElementById(_cat+"_"+_name+"_text").style="color:black;"
  725. if (_select) {
  726. var textToFind;
  727. textToFind = NUMBERS[_number][_cat][_name]["value1"];
  728. var dd = document.getElementById(_cat+"_"+_name+"_value1");
  729. for (var i = 0; i < dd.options.length; i++) {
  730. if (dd.options[i].text.toLowerCase() === textToFind.toLowerCase()) {
  731. dd.selectedIndex = i;
  732. break;
  733. }
  734. }
  735. }
  736. else {
  737. for (var j = 1; j <= _anzpara; ++j)
  738. document.getElementById(_cat+"_"+_name+"_value"+j).value = NUMBERS[_number][_cat][_name]["value"+j];
  739. }
  740. }
  741. }
  742. else
  743. {
  744. {
  745. if (_optional) {
  746. document.getElementById(_cat+"_"+_name+"_enabled").checked = _param[_cat][_name]["enabled"];
  747. for (var j = 1; j <= _anzpara; ++j)
  748. document.getElementById(_cat+"_"+_name+"_value"+j).disabled = !_param[_cat][_name]["enabled"];
  749. }
  750. document.getElementById(_cat+"_"+_name+"_text").style="color:black;"
  751. if (_select) {
  752. var textToFind;
  753. textToFind = _param[_cat][_name]["value1"];
  754. var dd = document.getElementById(_cat+"_"+_name+"_value1");
  755. for (var i = 0; i < dd.options.length; i++) {
  756. if (dd.options[i].text.toLowerCase() === textToFind.toLowerCase()) {
  757. dd.selectedIndex = i;
  758. break;
  759. }
  760. }
  761. }
  762. else {
  763. for (var j = 1; j <= _anzpara; ++j)
  764. document.getElementById(_cat+"_"+_name+"_value"+j).value = _param[_cat][_name]["value"+j];
  765. }
  766. }
  767. }
  768. ///////////////// am Ende, falls Kategorie als gesamtes nicht ausgewählt --> deaktivieren
  769. if (_category[_cat]["enabled"] == false)
  770. {
  771. if (_optional) {
  772. document.getElementById(_cat+"_"+_name+"_enabled").disabled = true;
  773. for (var j = 1; j <= _anzpara; ++j) {
  774. document.getElementById(_cat+"_"+_name+"_value"+j).disabled = true;
  775. }
  776. }
  777. document.getElementById(_cat+"_"+_name+"_text").style="color:lightgrey;"
  778. }
  779. EnDisableItem(_category[_cat]["enabled"], _param, _category, _cat, _name, _optional);
  780. }
  781. function InvertEnableItem(_cat, _param)
  782. {
  783. _zw = _cat + "_" + _param + "_enabled";
  784. _isOn = document.getElementById(_zw).checked;
  785. _color = "color:lightgrey;";
  786. if (_isOn) {
  787. _color = "color:black;";
  788. }
  789. _zw = _cat + "_" + _param + "_text";
  790. document.getElementById(_zw).disabled = !_isOn;
  791. document.getElementById(_zw).style = _color;
  792. if (param[_cat][_param]["anzParam"] == 2) {
  793. _color = "width: 30px;" + _color;
  794. }
  795. for (var j = 1; j <= param[_cat][_param]["anzParam"]; ++j) {
  796. document.getElementById(_cat+"_"+_param+"_value"+j).disabled = !_isOn;
  797. document.getElementById(_cat+"_"+_param+"_value"+j).style=_color;
  798. }
  799. }
  800. function EnDisableItem(_status, _param, _category, _cat, _name, _optional, _number = -1)
  801. {
  802. _status = _category[_cat]["enabled"];
  803. _color = "color:lightgrey;";
  804. if (_status) {
  805. _color = "color:black;";
  806. }
  807. if (_optional) {
  808. document.getElementById(_cat+"_"+_name+"_enabled").disabled = !_status;
  809. document.getElementById(_cat+"_"+_name+"_enabled").style=_color;
  810. }
  811. if (_number == -1){
  812. if (!_param[_cat][_name]["enabled"]) {
  813. _status = false;
  814. _color = "color:lightgrey;";
  815. }
  816. }
  817. else
  818. if (!NUMBERS[_number][_cat][_name]["enabled"]) {
  819. _status = false;
  820. _color = "color:lightgrey;";
  821. }
  822. document.getElementById(_cat+"_"+_name+"_text").disabled = !_status;
  823. document.getElementById(_cat+"_"+_name+"_text").style = _color;
  824. if (_param[_cat][_name]["anzParam"] == 2) {
  825. _color = "width: 30px;" + _color;
  826. }
  827. for (var j = 1; j <= _param[_cat][_name]["anzParam"]; ++j) {
  828. document.getElementById(_cat+"_"+_name+"_value"+j).disabled = !_status;
  829. document.getElementById(_cat+"_"+_name+"_value"+j).style=_color;
  830. }
  831. }
  832. function ReadParameter(_param, _cat, _name, _optional, _select = false, _number = -1){
  833. if (_number > -1)
  834. {
  835. if (_cat == "Digits")
  836. _cat = "digit"
  837. if (_cat == "Analog")
  838. _cat = "analog"
  839. if (_optional) {
  840. NUMBERS[_number][_cat][_name]["enabled"] = document.getElementById(_cat+"_"+_name+"_enabled").checked;
  841. }
  842. if (_select) {
  843. var sel = document.getElementById(_cat+"_"+_name+"_value1");
  844. NUMBERS[_number][_cat][_name]["value1"] = sel.options[sel.selectedIndex].text;
  845. }
  846. else {
  847. for (var j = 1; j <= _param[_cat][_name]["anzParam"]; ++j) {
  848. NUMBERS[_number][_cat][_name]["value"+j] = document.getElementById(_cat+"_"+_name+"_value"+j).value;
  849. }
  850. }
  851. }
  852. else
  853. {
  854. if (_optional) {
  855. _param[_cat][_name]["enabled"] = document.getElementById(_cat+"_"+_name+"_enabled").checked;
  856. }
  857. if (_select) {
  858. var sel = document.getElementById(_cat+"_"+_name+"_value1");
  859. _param[_cat][_name]["value1"] = sel.options[sel.selectedIndex].text;
  860. }
  861. else {
  862. for (var j = 1; j <= _param[_cat][_name]["anzParam"]; ++j) {
  863. _param[_cat][_name]["value"+j] = document.getElementById(_cat+"_"+_name+"_value"+j).value;
  864. }
  865. }
  866. }
  867. }
  868. function UpdateInputIndividual()
  869. {
  870. if (NUNBERSAkt != -1)
  871. {
  872. ReadParameter(param, "PostProcessing", "DecimalShift", true, false, NUNBERSAkt)
  873. }
  874. var sel = document.getElementById("Numbers_value1");
  875. NUNBERSAkt = sel.selectedIndex;
  876. WriteParameter(param, category, "PostProcessing", "DecimalShift", true, false, 1, NUNBERSAkt);
  877. }
  878. function UpdateInput() {
  879. document.getElementById("Category_Analog_enabled").checked = category["Analog"]["enabled"];
  880. document.getElementById("Category_Digits_enabled").checked = category["Digits"]["enabled"];
  881. document.getElementById("Category_MQTT_enabled").checked = category["MQTT"]["enabled"];
  882. WriteParameter(param, category, "MakeImage", "LogImageLocation", true);
  883. WriteParameter(param, category, "MakeImage", "LogfileRetentionInDays", true);
  884. WriteParameter(param, category, "MakeImage", "WaitBeforeTakingPicture", false);
  885. WriteParameter(param, category, "MakeImage", "ImageQuality", false);
  886. WriteParameter(param, category, "MakeImage", "Brightness", false);
  887. // WriteParameter(param, category, "MakeImage", "Contrast", false);
  888. // WriteParameter(param, category, "MakeImage", "Saturation", false);
  889. WriteParameter(param, category, "MakeImage", "ImageSize", false, true, true);
  890. WriteParameter(param, category, "MakeImage", "FixedExposure", false, true, true);
  891. WriteParameter(param, category, "Alignment", "SearchFieldX", false);
  892. WriteParameter(param, category, "Alignment", "SearchFieldY", false);
  893. WriteParameter(param, category, "Alignment", "AlignmentAlgo", true, true, true);
  894. WriteParameter(param, category, "Digits", "Model", false);
  895. WriteParameter(param, category, "Digits", "LogImageLocation", true);
  896. WriteParameter(param, category, "Digits", "LogfileRetentionInDays", true);
  897. WriteParameter(param, category, "Digits", "ModelInputSize", false, false, 2);
  898. WriteParameter(param, category, "Analog", "Model", false);
  899. WriteParameter(param, category, "Analog", "LogImageLocation", true);
  900. WriteParameter(param, category, "Analog", "LogfileRetentionInDays", true);
  901. WriteParameter(param, category, "Analog", "ExtendedResolution", true, true);
  902. WriteParameter(param, category, "Analog", "ModelInputSize", false, false, 2);
  903. WriteParameter(param, category, "PostProcessing", "PreValueUse", true, true);
  904. WriteParameter(param, category, "PostProcessing", "PreValueAgeStartup", true);
  905. WriteParameter(param, category, "PostProcessing", "AllowNegativeRates", true, true);
  906. WriteParameter(param, category, "PostProcessing", "MaxRateValue", true);
  907. WriteParameter(param, category, "PostProcessing", "ErrorMessage", true, true);
  908. WriteParameter(param, category, "PostProcessing", "CheckDigitIncreaseConsistency", true, true);
  909. WriteParameter(param, category, "MQTT", "Uri", true);
  910. WriteParameter(param, category, "MQTT", "MainTopic", true);
  911. WriteParameter(param, category, "MQTT", "ClientID", true);
  912. WriteParameter(param, category, "MQTT", "user", true);
  913. WriteParameter(param, category, "MQTT", "password", true);
  914. WriteParameter(param, category, "AutoTimer", "AutoStart", false, true);
  915. WriteParameter(param, category, "AutoTimer", "Intervall", false);
  916. WriteParameter(param, category, "Debug", "Logfile", true, true);
  917. WriteParameter(param, category, "Debug", "LogfileRetentionInDays", true);
  918. WriteParameter(param, category, "System", "TimeZone", true);
  919. WriteParameter(param, category, "System", "Hostname", true);
  920. WriteParameter(param, category, "System", "TimeServer", true);
  921. }
  922. function ReadParameterAll()
  923. {
  924. category["Analog"]["enabled"] = document.getElementById("Category_Analog_enabled").checked;
  925. category["Digits"]["enabled"] = document.getElementById("Category_Digits_enabled").checked;
  926. category["MQTT"]["enabled"] = document.getElementById("Category_MQTT_enabled").checked;
  927. ReadParameter(param, "MakeImage", "LogImageLocation", true);
  928. ReadParameter(param, "MakeImage", "LogfileRetentionInDays", true);
  929. ReadParameter(param, "MakeImage", "WaitBeforeTakingPicture", false);
  930. ReadParameter(param, "MakeImage", "ImageQuality", false);
  931. ReadParameter(param, "MakeImage", "Brightness", false);
  932. // ReadParameter(param, "MakeImage", "Contrast", false);
  933. // ReadParameter(param, "MakeImage", "Saturation", false);
  934. ReadParameter(param, "MakeImage", "ImageSize", false, true);
  935. ReadParameter(param, "MakeImage", "FixedExposure", false, true);
  936. ReadParameter(param, "Alignment", "SearchFieldX", false);
  937. ReadParameter(param, "Alignment", "SearchFieldY", false);
  938. ReadParameter(param, "Alignment", "AlignmentAlgo", true, true);
  939. ReadParameter(param, "Digits", "Model", false);
  940. ReadParameter(param, "Digits", "LogImageLocation", true);
  941. ReadParameter(param, "Digits", "LogfileRetentionInDays", true);
  942. ReadParameter(param, "Digits", "ModelInputSize", false, false);
  943. ReadParameter(param, "Analog", "Model", false);
  944. ReadParameter(param, "Analog", "LogImageLocation", true);
  945. ReadParameter(param, "Analog", "LogfileRetentionInDays", true);
  946. ReadParameter(param, "Analog", "ExtendedResolution", true, true);
  947. ReadParameter(param, "Analog", "ModelInputSize", false, false);
  948. ReadParameter(param, "PostProcessing", "PreValueUse", true, true);
  949. ReadParameter(param, "PostProcessing", "PreValueAgeStartup", true);
  950. ReadParameter(param, "PostProcessing", "AllowNegativeRates", true, true);
  951. ReadParameter(param, "PostProcessing", "MaxRateValue", true);
  952. ReadParameter(param, "PostProcessing", "ErrorMessage", true, true);
  953. ReadParameter(param, "PostProcessing", "CheckDigitIncreaseConsistency", true, true);
  954. ReadParameter(param, "MQTT", "Uri", true);
  955. ReadParameter(param, "MQTT", "MainTopic", true);
  956. ReadParameter(param, "MQTT", "ClientID", true);
  957. ReadParameter(param, "MQTT", "user", true);
  958. ReadParameter(param, "MQTT", "password", true);
  959. ReadParameter(param, "AutoTimer", "AutoStart", false, true);
  960. ReadParameter(param, "AutoTimer", "Intervall", false);
  961. ReadParameter(param, "Debug", "Logfile", true, true);
  962. ReadParameter(param, "Debug", "LogfileRetentionInDays", true);
  963. ReadParameter(param, "System", "TimeZone", true);
  964. ReadParameter(param, "System", "Hostname", true);
  965. ReadParameter(param, "System", "TimeServer", true);
  966. UpdateInputIndividual();
  967. // FormatDecimalValue(param, "PostProcessing", "MaxRateValue");
  968. }
  969. function WriteConfig(){
  970. ReadParameterAll();
  971. return setConfigParameters(param, category);
  972. }
  973. function FormatDecimalValue(_param, _cat, _name) {
  974. for (var j = 1; j <= _param[_cat][_name]["anzParam"]; ++j) {
  975. var _val = _param[_cat][_name]["value"+j];
  976. _val = _val.replace(",", ".");
  977. _param[_cat][_name]["value"+j] = _val;
  978. }
  979. }
  980. function UpdateAfterCategoryCheck() {
  981. ReadParameterAll();
  982. category["Analog"]["enabled"] = document.getElementById("Category_Analog_enabled").checked;
  983. category["Digits"]["enabled"] = document.getElementById("Category_Digits_enabled").checked;
  984. category["MQTT"]["enabled"] = document.getElementById("Category_MQTT_enabled").checked;
  985. UpdateInput();
  986. UpdateInputIndividual();
  987. }
  988. function UpdateExpertModus()
  989. {
  990. var _style = 'display:none;';
  991. if (document.getElementById("ExpertModus_enabled").checked) {
  992. _style = '';
  993. document.getElementById("Edit_Config_Direct").style.display = "";
  994. }
  995. else
  996. {
  997. document.getElementById("Edit_Config_Direct").style.display = "none";
  998. }
  999. const expert = document.querySelectorAll(".expert");
  1000. for (var i = 0; i < expert.length; i++) {
  1001. document.getElementById(expert[i].id).style = _style;
  1002. }
  1003. }
  1004. function saveTextAsFile()
  1005. {
  1006. if (confirm("Are you sure you want to update \"config.ini\"?")) {
  1007. ReadParameterAll();
  1008. WriteConfigININew();
  1009. SaveConfigToServer(basepath);
  1010. }
  1011. }
  1012. function doReboot() {
  1013. if (confirm("Are you sure you want to reboot the ESP32?")) {
  1014. var stringota = "/reboot";
  1015. window.location = stringota;
  1016. window.location.href = stringota;
  1017. window.location.assign(stringota);
  1018. window.location.replace(stringota);
  1019. }
  1020. }
  1021. function editConfigDirect() {
  1022. if (confirm("Did you save your changes?")) {
  1023. var stringota = "/edit_config.html";
  1024. window.location = stringota;
  1025. window.location.href = stringota;
  1026. window.location.assign(stringota);
  1027. window.location.replace(stringota);
  1028. }
  1029. }
  1030. function numberChanged()
  1031. {
  1032. UpdateInputIndividual();
  1033. }
  1034. LoadConfigNeu();
  1035. </script>
  1036. </body>
  1037. </html>