SerafinTech / node-red-contrib-cip-st-ethernet-ip

A Node-RED node to interact with Allen Bradley / Rockwell PLCs. SerafinTech Version
GNU General Public License v3.0
2 stars 3 forks source link

Reading a value from a matrix (bidimensional array) of STRING_8 cause the write of truncated string on plc #2

Open bombjackit opened 7 months ago

bombjackit commented 7 months ago

Describe the bug

In Eth IP In, reading 2 tags of type STRING_8 in a matrix (10,2), x in the example belowe, cause the rewrite of the smaller string in the plc.

For example, I read x[0,1] (value "AABBCC") and x[0,0] (value "DDEEFFGG") : at first read of x[0,0] assume the value "DDEEFF" (it was write on plc), I have noted that has same lenght of x[0,1].

Expected behavior

Eth IP In must not write data to plc in any case

Environment

Original post https://github.com/st-one-io/node-red-contrib-cip-ethernet-ip/issues/44

bombjackit commented 7 months ago

Going deeper on this issue, I discovered that if I read tags of type STRING_8 I had the same problem (not only inside an array but single tag) : maybe there is something correlate to the order of inserted tags inside the configuration (like #3 )

SerafinTech commented 7 months ago

The current ST-ethernet-ip library only supports standard STRING types. Will put this on the TODO list.

SerafinTech commented 7 months ago

Fixed String issue. Update to new version