fgsotres
Member
Hi,
Right now Im working with a Wenglor vision system connected to a Beckhoff PLC. From the camera im getting a string of measurement that i send it to the PLC via TCP/IP. The time rate of the measurement is 250 ms.
In the software, I want to take the measurement and create an array of strings in order to filter this information.
Now, my problem is that every cycle I get a string, the array is totally filled with the same string.
My code is the following:[/SIZE]
Any suggestion?
Right now Im working with a Wenglor vision system connected to a Beckhoff PLC. From the camera im getting a string of measurement that i send it to the PLC via TCP/IP. The time rate of the measurement is 250 ms.
In the software, I want to take the measurement and create an array of strings in order to filter this information.
Now, my problem is that every cycle I get a string, the array is totally filled with the same string.
My code is the following:[/SIZE]
Code:
VAR
serie : STRING;
var2: ARRAY[0..10] OF STRING;
i: INT;
END_VAR
serie:=MAIN.fbClient1.sFromServer; *This is the string that i get from the camera
IF i <=10
THEN
var2[i]:=serie;
i:=i+1;
ELSE
i:=0;
END_IF;
Any suggestion?