L-force | plc designer – Lenze PLC Designer PLC Designer (R2-x) User Manual

Page 271

Advertising
background image

L-force | PLC Designer

Editors in PLC Designer



DMS 3.2 EN 02/2011 TD29

269

Neither variable will be initialized:

{flag noinit on}

VAR
a : INT;
b : INT;

END_VAR

{flag off}

VAR
{flag noinit on}
a : INT;

b : INT;

{flag off}

END_VAR

Getting variables to the symbol file:

The flags „noread" and „nowrite" are used, in a POU that has read and/or write
permission, to provide selected variables with restricted access rights. The default for
the variable is the same as the setting for the POU in which the variable is declared. If
a variable has neither read nor write permission, it will not be exported into the
symbol file.

Examples:

If the POU has read and write permission, then with the following pragmas variable a
can only be exported with write permission, while variable b can not be exported at
all:

VAR
a : INT {flag noread};
b : INT {flag noread, nowrite};

END_VAR

VAR
{ flag noread on}
a : INT;
{ flag noread, nowrite on}
b : INT;
{flag off}

END_VAR

Advertising