Wstring, References, L-force | plc designer – Lenze PLC Designer PLC Designer (R3-1) User Manual

Page 1025

Advertising
background image

L-force | PLC Designer

Programming Reference

DMS 4.1 EN 03/2011 TD29

1023

Example:
LTIME1 := LTIME#1000d15h23m12s34ms2us44ns
Compare to TIME: size 32 Bit and resolution milliseconds.

wstring
This string data type is an extension to the IEC 61131-3 standard.
It differs from the standard STRING type (ASCII) by getting interpreted in Unicode
format.
Example:

wstr:WSTRING:="This is a WString";


See also:
• STRING
• STRING constants (Operands)

References
This data type is an extension to the IEC 61131-3 standard.
A REFERENCE is an alias for an object. The alias can be written or read via identifiers.
The difference to a pointer is that the value pointed to is directly affected and that the
assignment of reference and value is fix. The address of the reference must be set via a
separate assignement operation. Whether a reference points to a valid value (that is
unequal 0) can be checked with the help of a special operator, see below.
A reference is declared according to the following syntax:
Syntax
<identifier> : REFERENCE TO <data type>
Example declaration:

ref_int : REFERENCE TO INT;
a : INT;
b : INT;

ref_int is now available for being used as an alias for variables of type INT.

Advertising