lauwerstim
Member
I'm creating an FB with a variable input and I would like to copy all of the bits to an array (declared as temp)
I've declared the array in TEMP: Array_TEMP;Array [1..100] of bool
I've declared the input pointer: First_SI; pointer
I read in the pointer and can get its data, but copying to the array doesn't work. This is my code so far:
When I read the first BOOL (A DBX [#TempPoint]) the outcome is correct but I can't pass it on to the array in indirect fashion. (the goal is to create a loop to copy all 100tags)
I've declared the array in TEMP: Array_TEMP;Array [1..100] of bool
I've declared the input pointer: First_SI; pointer
I read in the pointer and can get its data, but copying to the array doesn't work. This is my code so far:
Code:
L P##First_SI
LAR1
L W [AR1,P#0.0]
T #iDB
OPN DB [#iDB]
L D [AR1,P#2.0]
L P#0.0
+I
T #TempPoint
A DBX [#TempPoint]
= #Array_TEMP[ [I][COLOR="Red"]what goes here?[/COLOR][/I]]
When I read the first BOOL (A DBX [#TempPoint]) the outcome is correct but I can't pass it on to the array in indirect fashion. (the goal is to create a loop to copy all 100tags)