Open liulysk opened 1 year ago
In this code, calling the subflow multiple times creates multiple connections to the PLC and this does not scale well, as the PLC has a maximum number of connections. (If you don't drop the connection, the connection stays open, and a new call creates a new connection, which is why not dropping the connection causes things to fail after a short time) If you want to read a lot of data, this should be done either in series (making sure you finish reading and drop a connection before establishing another) or read everything all at once on one connection which is most efficient. If you want 200 structures, put all the items you want to read in an array first, then add all the items using addItems and it should read them all at once, far more efficiently than with 200 connections.
If I don't drop connection I receive:.
after a few requests and connection never comes alive.
Is uncommenting lines
the only way to keep connection stable? My code
Full nodered subflow:
I'm trying to read multiple identical structures with different offsets. Addressing has to be done dynamically that's why I can't use existing Nodered nodes.
Is there a way to read ~200structures, Max I get stable is ~40. I've tried to connect all in series also. I thought maybe keeping connection alive would help, but I cannot get more calls.![image](https://user-images.githubusercontent.com/115482988/194895429-af571040-5de0-4e11-b6b5-2af1c43a071e.png)