The operator saves/copies the contents of the vector to the specified memory address. The number and the types of elements are automatically applied from the vector variables.




NOTICE

__VCSTORE(<n>,<ptr>)
writes <n>
successive values at the <ptr>
address. If there are less than <n>
values at this address, then this can cause the controller to crash or write unwanted
memory.
Syntax
__VCSTORE( <pointer to data>, <vector variable> );
Save
FUNCTION_BLOCK FB_STORE VAR_INPUT END_VAR VAR_OUTPUT END_VAR VAR rData : ARRAY[0..2] OF REAL := [1, 2, 3]; pData: POINTER TO REAL := ADR(rData[0]); lrData : ARRAY [0..3] OF LREAL := [1, 2, 3, 4]; plData: POINTER TO LREAL := ADR(lrData[0]; vcA : __VECTOR[3] OF REAL := __VCSET_REAL( 1.234, 5.678, 9.123); vclA : __VECTOR[4] OF LREAL := __VCSET_LREAL(-1.7976931348623158E+308, 1.6E+308, 1.7E+308, -1.6E+308); END_VAR __VCSTORE(pData, vcA); __VCSTORE(plData, vclA);