Queueing and throttling in logic machine - 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: Queueing and throttling in logic machine (/showthread.php?tid=5669) |
Queueing and throttling in logic machine - achang - 15.10.2024 Hello, I have a system where at times, a good number of commands will be sent to the logic machine. Currently, I am controlling the number of commands sent to the logic machine within my backend code of the system, setting delay times for each command because if I send too many commands at once, the CPU/load of the logic machine will increase and some commands are lost during the process. I want to make it so that I can send the commands all at once, and queue the group addresses/values that have been sent within the Logic Machine, and execute grp.write() when the CPU/load is back to normal. I would say I'm looking to implement something close to API rate limits, and I believe there are multiple ways to do this. Any suggestions/recommendations on how to do this? Thanks in advance! RE: Queueing and throttling in logic machine - Daniel - 15.10.2024 Is it IP or TP? RE: Queueing and throttling in logic machine - achang - 15.10.2024 Thanks for the reply! We are using TP. RE: Queueing and throttling in logic machine - Daniel - 15.10.2024 Then your bottleneck is TP bus anyway. TP uart chip has its limits and the only thing you can do is to limit telegrams on the bus. In KNX settings you can set queue limit but if too many telegrams are sent at once then you will loose some. Some years ago I did some testing using standard KNX routers and the real limit was 20 telegrams at once. RE: Queueing and throttling in logic machine - achang - 16.10.2024 In that case, if it's not really useful to check the CPU or load of the Logic Machine, is there a way to check how much telegrams are transmitted through the TP bus so we can limit the amount of telegrams that might be sent when a command is executed? RE: Queueing and throttling in logic machine - admin - 16.10.2024 Can you describe your use case? Why do you need to send so many commands at once? |