Changes for page 09 Lua Editor

Last modified by Nhu Nguyen on 2025/03/09 17:22

From version 7.1
edited by Jim
on 2023/08/11 09:10
Change comment: There is no comment for this version
To version 9.2
edited by Nhu Nguyen
on 2025/03/09 17:22
Change comment: Added comment

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.Jim
1 +XWiki.nhunguyen95
Content
... ... @@ -140,7 +140,10 @@
140 140  * **Tens digit=1**: indicates that the function or global variable defined in this file can be used in the background code file (Script_BG.lua). If it is 0, it is not available.
141 141  * **Ones digit=1**: indicates that the functions or global variables defined in this file can be used in the screen code file (Script_Screen.lua) or LuaScript components. If it is 0, it is not available.
142 142  
143 +(% class="box infomessage" %)
144 +(((
143 143  **✎Note: **If you rename the file manually, you must modify the limits in the file accordingly, otherwise the script file will not take effect.
146 +)))
144 144  
145 145  == Built-In script file ==
146 146  
... ... @@ -165,7 +165,10 @@
165 165  
166 166  The above is the initialization function of screen 0. For screen 100, you can replace 0 with 100. You can add your own function: function we_scr_init_100() end
167 167  
171 +(% class="box infomessage" %)
172 +(((
168 168  **✎Note: **The above function has a fixed name. If it is modified, it will not cause crash, but the function can be found.
174 +)))
169 169  
170 170  **Example:** After the screen 0 initialization function is changed to we_scR_init_0(), the script will not be executed when screen 0 is initialized, and then no script will be executed, and nothing will be done because the "we_scr_init_0" function cannot be found.
171 171  
XWiki.XWikiComments[0]
Date
... ... @@ -1,0 +1,1 @@
1 +2025-03-09 17:22:36.258
Author
... ... @@ -1,0 +1,1 @@
1 +XWiki.nhunguyen95
Comment
... ... @@ -1,0 +1,1 @@
1 +hello, i am using wecon pi3070ig monitor product and i want to use it to control thermal monitoring device. my thermal monitoring device will send thermal information via rs485 communication when receiving thermal reading command with syntax: "STX001,RRD,01,0100", the returned information will be in the form of "STX001,RRD,OK,(thermal parameter)". i want to ask if i can use lua script to send the above data reading command?