Structures - Mitsubishi Electric MELSEC iQ-F Series Programming Manual

Hide thumbs Also See for MELSEC iQ-F Series:
Table of Contents

Advertisement

■Array elements
When accessing the element defined in an array, access it within the range of the number of elements.
If a constant out of the range defined for the array index is specified, a compile error will occur.
If the array index is specified with data other than a constant, a compile error will not occur. The processing will be performed
by accessing another label area or latch label area.
4.5

Structures

A structure is a data type that includes different labels. Structures can be used in all POUs.
Each member (label) included in a structure can be defined even when the data types are different.
Creating structures
To create a structure, first create the configuration of the structure, and define members for the created structure.
Structure
Member (Label 1)
Member (Label 2)
Member (Label 3)
Member (Label 4)
How to use structures
To use structures, register the label with the defined structure as a new data type.
To specify each member, append an element name after the structure label name with "period (.)" as a member name.
Ex.
When using the member of a structure
stLabel1 . bLabel1
• When labels are registered by defining multiple data types in a structure and used in a program, the order
the data is stored after converted is not the order the data types were defined. When programs are
converted using the engineering tool, labels are classified into type and data type, and then assigned to the
memory (memory assignment by packing blocks).
GX Works3 Operating Manual
• If a member of a structure is specified in an instruction operand that uses control data (series of consecutive
devices from the operand used by the instruction), the control data is assigned to members of the structure
by the order they are stored in memory, not the order the members are defined.
4 LABELS
38
4.5 Structures
Member name
Structure label name

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melsec iq-f fx5

Table of Contents