FAN SPEEDS TO TEXT - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: FAN SPEEDS TO TEXT (/showthread.php?tid=3560) |
FAN SPEEDS TO TEXT - d.r soutras - 15.09.2021 Hello guys. I need your help. I have a w4k and i need to convert the vrv speeds to text. So the AUTO is 0 The LOW is 1 to 33 The MEDIUM is 34 to 67 The HIGH is 68 to 100. The GA is 1byte unsigned integer. The script that i want to create will have the 1 byte as an input and i will write the result in an other GA with the desired string/text. I m attaching a photo of the visualization. RE: FAN SPEEDS TO TEXT - Erwin van der Zwart - 15.09.2021 Code: textobject ='1/1/1' RE: FAN SPEEDS TO TEXT - d.r soutras - 17.09.2021 Thank you Erwin again for your quick reply! You are a life saver! Your script works like a charm!!!! RE: FAN SPEEDS TO TEXT - admin - 20.09.2021 Another option is to generate text labels via a script and use them as Custom values (enums): Code: text = {} RE: FAN SPEEDS TO TEXT - d.r soutras - 20.09.2021 Thank you very much admin! RE: FAN SPEEDS TO TEXT - khalil - 27.06.2022 Hello all How to change custom values via JS BR, RE: FAN SPEEDS TO TEXT - admin - 27.06.2022 Custom values can only be changed from Lua side. Visualization has to be reloaded for new value to appear. Why do you need to change these value from JS? RE: FAN SPEEDS TO TEXT - khalil - 27.06.2022 (27.06.2022, 12:31)admin Wrote: Custom values can only be changed from Lua side. Visualization has to be reloaded for new value to appear. Why do you need to change these value from JS? Thanks Admin I aim to use it in this example https://forum.logicmachine.net/showthread.php?tid=4091, to change the custom value and icon via JS. While I should create 1byte object for the custom values (auto off, auto on, manual of, manual on, overload). then no need to write on Custom value I should write on new 1byte object |