Programming; Registering Labels - Mitsubishi Electric MELSEC iQ-R Series User Manual

Process cpu module
Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

4.9

Programming

Create a program. This section describes how to create a program using the following program example.
Program example
• When Start1 turns on, Timer1 starts counting, and Lamp1 turns on.
• When the current value of Timer1 reaches 1000, Lamp1 turns off.
• When Stop1 turns on, Lamp1 turns off.

Registering labels

Label is a variable whose name and data type can be declared by a user.
Use of labels allows programming without being aware of devices and buffer memory addresses. For this reason, programs
using labels can be used in other systems where the module configuration is different.
Labels can be registered on the label editor.
[Navigation window]  [Program]  [Scan]  [MAIN]  [ProgPou]  [Local Label]
Procedure
Register the label "Start1" in the program example, following the procedure below.
(1)
Register other labels in the program example in the same way.
• The class, initial value, and constant of labels can be set as needed by clicking the [Show Details] button on
the label editor.
• Labels can also be registered while programming without opening the label editor. ( Page 49 Inserting
POUs by key input)
• Devices can be assigned to global labels. Open the global label editor, and enter a device in the "Assign
(Device/Label)" field.
4 START-UP PROCEDURE
46
4.9 Programming
1.
2.
(2)
3.
Enter the name, "Start1", in the "Label Name" field (1).
Click the button (2) on the right of the "Data Type" field to open
the "Data Type Selection" window.
Specify the data type. Select "Bit", and click the [OK] button.

Advertisement

Table of Contents
loading

Table of Contents