![Mitsubishi Electric MELSEC iQ-R C R12CCPU-V User Manual Download Page 59](http://html.mh-extra.com/html/mitsubishi-electric/melsec-iq-r-c-r12ccpu-v/melsec-iq-r-c-r12ccpu-v_user-manual_239137059.webp)
4 BASIC FUNCTIONS
4.8 Label Communication Function
57
4
4.8
Label Communication Function
Data can be read from/written to labels stored in CPU modules of other stations.
Label communication flow
1.
Acquire label assignment information (device information) of the specified label by using the MELSEC data link function
(mdGetLabelInfo).
2.
Read/write data from/to a device based on the acquired label assignment information (device information) by using the
MELSEC data link functions (mdRandRLabelEx/mdRandWLabelEx).
• In the label communication, a CPU module can be accessed without changing a user program by acquiring
label assignment information again even if the label assignment information of the CPU module is changed.
• The label assignment information (device information) acquired by using the MELSEC data link function
(mdGetLabelInfo) does not need to be acquired for each MELSEC data link function (mdRandRLabelEx/
mdRandWLabelEx) execution. However, if the label assignment information (device information) stored in a
CPU module is changed, acquire it again by using the MELSEC data link function (mdGetLabelInfo).
(Otherwise, an error response is returned.)
■
User program functions
The following table shows the functions used for label communication.
Function name
Description
mdGetLabelInfo
To acquire device information corresponding to label names.
mdRandRLabelEx
To read devices corresponding to labels randomly.
mdRandWLabelEx
To write devices corresponding to labels randomly.
Label1
Label2
Label3
D0
D1
X0
C Controller module
(reference side)
CPU module
(Label definition side)
User program
Obtain an information of the corresponding
devices using specified label (Label1, Label2).
1.Execute the mdGetLabelInfo function.
Label assignment information
Assignment target
(Device name)
Label name
Execute Reading/Writing for the device
corresponding to the label.
2.Execute the
mdRandRLabelEx/mdRandWLabelEx
functions.
Summary of Contents for MELSEC iQ-R C R12CCPU-V
Page 1: ...MELSEC iQ R C Controller Module User s Manual Application R12CCPU V ...
Page 2: ......
Page 23: ...1 EXECUTING PROGRAMS 1 3 I O Access Timing 21 1 MEMO ...
Page 32: ...30 3 MEMORY CONFIGURATION OF C Controller Module 3 4 Files MEMO ...
Page 257: ...I 255 MEMO ...
Page 261: ......