Hi all,

while investigating: https://issues.apache.org/jira/browse/PLC4X-240 I noticed 
that the reading of STRING types seems to be extremely inefficient.

The reason is that we are currently reading a STRING element by reading 258 
bytes (1 byte for MAX num of chars, 1 byte for ACT num of chars and then 256 
bytes containing char data).

The problem is that with a PDU-Size of 240 you can’t read one STRING with only 
one packet. With a S7 1500 or 400 it might work as they have larger PDU sizes. 
Currently the 0.6 drivers split this up into 2 requests.

But it’s highly inefficient as usually the content will not be anywhere near 
the 256 chars.

So my idea is to only request one byte (the ACT size) of the String and as soon 
as that’s returned, to ask for only the chars that are actually used. This 
should drastically reduce the payload on the wire.

What do you think?

Chris

Reply via email to