Program Example - Mitsubishi Electric MELSEC-Q Series User Manual

Cc-link system master/local module
Hide thumbs Also See for MELSEC-Q Series:
Table of Contents

Advertisement

9.3.1

Program example

This section shows an example of the program to write 10-word data from the area starting from D0 in the master
station to the area starting from D1000 in the local station (station number 1) when X0 is turned on in the following
system configuration.
• Assume that the I/O number of the master station is X/Y40 to X/Y5F.
• Assume that SW0 is set to the refresh device of the link special register (SW).
• M13 is the G(P).RIWT instruction executing flag.
CPU module
RIWT request
source
(Host station)
D0
to
D9
186
Master station
Station No.0
Send
buffer
CPU module
RIWT request
target
(Target station)
D1000
to
D1009
Perform process for receive
completion.
Perform process for normal
completion.
Perform process for abnormal
end.
Local station
Station No.1
Control data setting
Dedicated instruction execution
Set G(P).RIWT instruction
executing flag to ON.
Process upon completion of
reception
Process upon normal completion
of dedicated instruction
Process upon abnormal end of
dedicated instruction
Set G(P).RIWT instruction
executing flag to OFF.

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents