![]() |
Stop execution of KNX secuence - 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: Stop execution of KNX secuence (/showthread.php?tid=972) |
Stop execution of KNX secuence - ivanposada - 31.08.2017 Hello from Spain, i have a script with a secuence in KNX, using "os.sleep(t)" to do a delay between telegrams. It works well, but in any case, the secuence duration is 4-5 minutes. ¿How can i do to stop the secuence in the middle of execution? Any "break" or "exit" or "kill" exception to stop the script. Code: os.sleep(23) Thanks! Iván. RE: Stop execution of KNX secuence - admin - 31.08.2017 You can use an object or a storage variable as a status, then check this status after each sleep: Code: os.sleep(23) RE: Stop execution of KNX secuence - ivanposada - 05.09.2017 (31.08.2017, 11:29)admin Wrote: You can use an object or a storage variable as a status, then check this status after each sleep: Thanks admin!! It works! The inconvenience is that i have to copy that a lot of times in the code, but it works. Ivan. RE: Stop execution of KNX secuence - buuuudzik - 05.09.2017 You can prepare some table with values and then iterate over it with some loop.This is only a little inspiration ![]() Code: pause = 14 -- seconds RE: Stop execution of KNX secuence - Erwin van der Zwart - 05.09.2017 Hi Buuuudzik, Check your sample (: statusGA is a address (string) and not a value so will never be false (bool) BR, Erwin RE: Stop execution of KNX secuence - buuuudzik - 06.09.2017 Thanks, yes I've updated the above script ![]() |