Operator ‘MOVE’

This IEC operator is used for assigning a variable to another variable of a corresponding type.

Because the MOVE block is available in the CFC, FBD, and LD editors, you can also use the EN/ENO functionality for variable assignment.

CFC with EN/ENO function:

CODESYS assigns the value of var1 to var2 only if “en_i” yields TRUE.

../_images/8afc5392ac86e9edc0a8640e01a7120b

ST:

ivar2 := MOVE(ivar1);

This corresponds to:

ivar2 := ivar1;