bcnp59990381t
bcnp59990381t
Under some circumstances, failure to observe the precautions given under " CAUTION" may lead to serious
consequences.
Observe the precautions of both levels because they are important for personal and system safety.
Make sure that the end users read this manual and then keep the manual in a safe place for future reference.
1
CONDITIONS OF USE FOR THE PRODUCT
(1) MELSEC programmable controller ("the PRODUCT") shall be used in conditions;
i) where any problem, fault or failure occurring in the PRODUCT, if any, shall not lead to any major or serious accident;
and
ii) where the backup and fail-safe function are systematically or automatically provided outside of the PRODUCT for the
case of any problem, fault or failure occurring in the PRODUCT.
(2) The PRODUCT has been designed and manufactured for the purpose of being used in general industries.
MITSUBISHI ELECTRIC SHALL HAVE NO RESPONSIBILITY OR LIABILITY (INCLUDING, BUT NOT LIMITED TO
ANY AND ALL RESPONSIBILITY OR LIABILITY BASED ON CONTRACT, WARRANTY, TORT, PRODUCT
LIABILITY) FOR ANY INJURY OR DEATH TO PERSONS OR LOSS OR DAMAGE TO PROPERTY CAUSED BY the
PRODUCT THAT ARE OPERATED OR USED IN APPLICATION NOT INTENDED OR EXCLUDED BY
INSTRUCTIONS, PRECAUTIONS, OR WARNING CONTAINED IN MITSUBISHI ELECTRIC USER'S, INSTRUCTION
AND/OR SAFETY MANUALS, TECHNICAL BULLETINS AND GUIDELINES FOR the PRODUCT.
("Prohibited Application")
Prohibited Applications include, but not limited to, the use of the PRODUCT in;
• Nuclear Power Plants and any other power plants operated by Power companies, and/or any other cases in which the
public could be affected if any problem or fault occurs in the PRODUCT.
• Railway companies or Public service purposes, and/or any other cases in which establishment of a special quality
assurance system is required by the Purchaser or End User.
• Aircraft or Aerospace, Medical applications, Train equipment, transport equipment such as Elevator and Escalator,
Incineration and Fuel devices, Vehicles, Manned transportation, Equipment for Recreation and Amusement, and
Safety devices, handling of Nuclear or Hazardous Materials or Chemicals, Mining and Drilling, and/or other
applications where there is a significant risk of injury to the public or property.
Notwithstanding the above restrictions, Mitsubishi Electric may in its sole discretion, authorize use of the PRODUCT in
one or more of the Prohibited Applications, provided that the usage of the PRODUCT is limited only for the specific
applications agreed to by Mitsubishi Electric and provided further that no special quality assurance or fail-safe,
redundant or other safety features which exceed the general specifications of the PRODUCTs are required. For details,
please contact the Mitsubishi Electric representative in your region.
(3) Mitsubishi Electric shall have no responsibility or liability for any problems involving programmable controller trouble and
system trouble caused by DoS attacks, unauthorized access, computer viruses, and other cyberattacks.
INTRODUCTION
Thank you for purchasing the Mitsubishi Electric MELSEC iQ-R series programmable controllers.
This manual describes the module function blocks for the relevant products listed below.
Before using the products, please read this manual and the relevant manuals carefully and develop familiarity with the
functions and performance of the MELSEC iQ-R series programmable controller to handle the products correctly.
When applying the program examples provided in this manual to an actual system, ensure the applicability and confirm that it
will not cause system control problems.
Please make sure that the end users read this manual.
Relevant products
Item Model
Ethernet-equipped module RJ71EN71, R04ENCPU, R08ENCPU, R16ENCPU, R32ENCPU, R120ENCPU
CC-Link IE TSN master/local module RJ71GN11-T2, RJ71GN11-SX
CC-Link IE TSN Plus master/local module RJ71GN11-EIP
CC-Link IE Controller Network module RJ71GP21-SX, RJ71GP21S-SX
CC-Link IE Field Network master/local module RJ71GF11-T2
MELSECNET/H network module RJ71LP21-25, RJ71BR11
2
CONTENTS
SAFETY PRECAUTIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1
CONDITIONS OF USE FOR THE PRODUCT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2
INTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2
RELEVANT MANUALS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6
TERMS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7
GENERIC TERMS AND ABBREVIATIONS. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8
CONTENTS
CHAPTER 1 OVERVIEW 9
1.1 Function Block (FB) List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
1.2 How to Obtain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.3 System Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
3
4.5 M+model_RemoteStopRun. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
4.6 M+model_SLMP_DeviceRead_IP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
4.7 M+model_SLMP_DeviceWrite_IP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
4.8 M+model_RemoteRead. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
4.9 M+model_RemoteWrite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 159
4.10 M+model_RemoteReset_IP. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160
4.11 M+model_RemoteReset2_IP. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
4.12 M+model_ConnectionOpen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162
4.13 M+model_ConnectionClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
4.14 M+model_Recv_Socket . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167
4.15 M+model_Send_Socket . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170
4.16 M+model_Refresh_Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
4
INSTRUCTION INDEX 229
REVISIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .231
TRADEMARKS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .232
CONTENTS
5
RELEVANT MANUALS
Manual name [manual number] Description Available
form
MELSEC iQ-R Ethernet, CC-Link IE, and Specifications of the module FBs of the following: e-Manual
MELSECNET/H Function Block Reference • MELSEC iQ-R Ethernet-equipped module PDF
[BCN-P5999-0381] (this manual) • CC-Link IE TSN master/local module
• CC-Link IE TSN Plus master/local module
• CC-Link IE Controller Network module
• CC-Link IE Field Network master/local module
• MELSECNET/H network module
MELSEC iQ-R Programming Manual (Module Dedicated instructions for the intelligent function modules e-Manual
Dedicated Instructions) PDF
[SH-081976ENG]
MELSEC iQ-R CPU Module User's Manual Memory, functions, devices, and parameters of the CPU module Print book
(Application)
e-Manual
[SH-081264ENG]
PDF
MELSEC iQ-R Ethernet User's Manual (Application) Functions, parameter settings, programming, troubleshooting, I/O signals, and Print book
[SH-081257ENG] buffer memory of Ethernet e-Manual
PDF
MELSEC iQ-R CC-Link IE TSN User's Manual Functions, parameter settings, troubleshooting, I/O signals, and buffer memory of Print book
(Application) CC-Link IE TSN
e-Manual
[SH-082129ENG]
PDF
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Specifications, procedures before operation, system configuration, wiring, functions, Print book
Module User's Manual parameter settings, programming, troubleshooting, I/O signals, and buffer memory
e-Manual
[SH-082472ENG] of the CC-Link IE TSN Plus master/local module
PDF
MELSEC iQ-R CC-Link IE Controller Network User's Functions, parameter settings, troubleshooting, and buffer memory of CC-Link IE Print book
Manual (Application) Controller Network
e-Manual
[SH-081258ENG]
PDF
MELSEC iQ-R CC-Link IE Field Network User's Functions, parameter settings, programming, troubleshooting, I/O signals, and Print book
Manual (Application) buffer memory of CC-Link IE Field Network e-Manual
[SH-081259ENG]
PDF
MELSEC iQ-R MELSECNET/H Network Module Functions, parameter settings, programming, troubleshooting, and buffer memory of Print book
User's Manual (Application) MELSEC iQ-R MELSECNET/H network module
e-Manual
[SH-082204ENG] PDF
e-Manual refers to the Mitsubishi Electric FA electronic book manuals that can be browsed using a dedicated
tool.
e-Manual has the following features:
• Required information can be cross-searched in multiple manuals.
• Other manuals can be accessed from the links in the manual.
• The hardware specifications of each part can be found from the product figures.
• Pages that users often browse can be bookmarked.
• Sample programs can be copied to an engineering tool.
6
TERMS
Unless otherwise specified, this manual uses the following terms.
Term Description
Engineering tool A tool used for setting up programmable controllers, programming, debugging, and maintenance
Module label A label that represents one of memory areas (I/O signals and buffer memory areas) specific to each module in a given
character string.
For the module used, GX Works3 automatically generates this label, which can be used as a global label.
7
GENERIC TERMS AND ABBREVIATIONS
Unless otherwise specified, this manual uses the following generic terms and abbreviations.
Generic term/abbreviation Description
CC-Link IE Controller Network-equipped module An RJ71GP21-SX CC-Link IE Controller Network module, an RJ71GP21S-SX CC-Link IE
Controller Network module, and the following modules when the CC-Link IE Controller Network
function is used:
• RJ71EN71
• RnENCPU (network part)
CC-Link IE Field Network-equipped master/local module An RJ71GF11-T2 CC-Link IE Field Network master/local module and the following modules when
the CC-Link IE Field Network function is used:
• RJ71EN71
• RnENCPU (network part)
Ethernet-equipped module A generic term for the following modules when the Ethernet function is used:
• RJ71EN71
• RnENCPU (network part)
MELSECNET/H An abbreviation for the MELSECNET/H network system
RnENCPU (network part) A module on the right-hand side of the RnENCPU ( MELSEC iQ-R Ethernet/CC-Link IE User's
Manual (Startup))
8
1 OVERVIEW
1
The FBs described in this reference are module FBs (for GX Works3) to be used in the MELSEC iQ-R series network
modules and the Ethernet function of the CPU module.
1 OVERVIEW
1.1 Function Block (FB) List 9
Name Description Ethernet CCIETSN CCIETSN CCIEC CCIEF NET/H
Plus
M+model_RemoteReset_IP Sends the remote STOP of an SLMP request
to the target station specified by an IP
address and then sends the remote RESET.
M+model_RemoteReset2_IP Sends the remote RESET of an SLMP
request to the target station specified by an IP
address.
M+model_SetParameter Sets the parameters in the master,
submaster, and local stations.
M+model Sets the parameters in the master station in
_SetParameterRedundant the redundant system.
M+model_StationNoSet Sets the station number of the own station.
M+model_RedundantSystem Identifies the control system or standby *1
_GetAddress system in the target (another station)
redundant system and acquires the address
of the control system or standby system in the
redundant system.
M+model Reads the model information of the system
_ReadSystemTypeInformation configuration module of the intelligent device
station (remote head module).
M+model Reads the status information of the system
_ReadSystemStatusInformation configuration module of the intelligent device
station (remote head module).
M+model_RemoteReset Sends a remote STOP request to the target
station and then sends a remote RESET
request.
1 OVERVIEW
10 1.2 How to Obtain
1.3 System Configuration
The following shows the system configuration for using the module FBs in this reference.
1
For the specifications of modules to be used, refer to the user's manual for each module.
Ethernet-equipped module
■RJ71GN11-SX
(1) (2) (2)
(3)
1 OVERVIEW
1.3 System Configuration 11
CC-Link IE TSN Plus master/local module
TSN HUB
(1) (2)
(3)
(3)
■When performing communications between the control station and normal station in a
redundant system
1 OVERVIEW
12 1.3 System Configuration
CC-Link IE Field Network master/local module
■When performing communications between the master station and local station 1
(1) (2)
(3)
■When performing communications between the master station and intelligent device station
(remote head module)
(1) (2)
1 OVERVIEW
1.3 System Configuration 13
MELSECNET/H network module
■When performing communications between the control station and normal station
• Optical loop system
(1) (2)
(1) (2)
■When performing communications between the control station and normal station in a
redundant system
1 OVERVIEW
14 1.3 System Configuration
2 Ethernet-EQUIPPED MODULE FB
2.1 M+model_DeviceRead
2
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_DeviceRead RJ71EN71(E+E)
M+RJ71EN71_C_DeviceRead RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_DeviceRead RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_DeviceRead RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_DeviceRead RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_DeviceRead
■RJ71GF11-T2
M+RJ71GF11_DeviceRead
■RJ71LP21-25
M+RJ71LP21_DeviceRead
■RJ71BR11
M+RJ71BR11_DeviceRead
Overview
Item Description
Overview Reads data by specifying a device in the programmable controller of another station.
Symbol
M+RJ71GF11_DeviceRead
(1) B: i_bEN o_bENO: B (7)
(2) DUT: i_stModule o_bOK: B (8)
(3) UW: i_u2TargetAddress o_bErr: B (9)
(4) UW: i_uDataLength o_uErrId: UW (10)
(5) S: i_s32TargetDevice o_uReadData: UW (11)
(6) UW: i_uChannel
pbi_uCPU_Type (12)
pbi_uResendCountMax (13)
pbi_uTimeUnit (14)
pbi_uMonitorTime (15)
pbi_bStationSpecific (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrNetworkNo (19)
pbo_uErrStationNo (20)
2 Ethernet-EQUIPPED MODULE FB
2.1 M+model_DeviceRead 15
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_u2TargetAddress Target station Word Specify the network number and station number of the target station when
address [Unsigned]/ "Target station address specification method" is off. When specifying the
Bit String address using a label, use an array as the data type.
[16-bit] • 1st word: Network number (1 to 239)
(0..1) • 2nd word: Station number
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
Specify the IP address of the target station when "Target station address
specification method" is on (Ethernet only). Specify the third and fourth
octets to the 1st word, and first and second octets to the 2nd word. When
specifying the address using a label, use an array as the data type.
• 00000001H to FFFFFFFEH
Note that the fourth octet cannot be set to 0 or 255 (FFH).
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uDataLength Read data length Word Specify the number of words to be read.
[Unsigned]/ • When reading data from RCPU, QCPU, or LCPU: 1 to 8192 words
Bit String • When reading data from QnACPU: 1 to 480 words
[16-bit] When specifying 961 words or more, specify 9 or 10 in "Own station
channel".
(5) i_s32TargetDevice Target station read Character Specify the start address of the target station from which data is to be read.
device string (32) The following cannot be specified as an argument. Specifying any of the
following may cause a CPU error (2820H: Device/label/buffer memory
specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
(6) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
2 Ethernet-EQUIPPED MODULE FB
16 2.1 M+model_DeviceRead
■Output arguments
No. Variable name Name Data type Description Default
value
(7) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(8) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
2
(9) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(10) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
(11) o_uReadData Read data storage Word Specify the start number of the device for storing the read data 0
device [Unsigned]/ The following cannot be specified as an argument. Specifying any of the
Bit String following may cause a CPU error (2820H: Device/label/buffer memory
[16-bit] specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(12) pbi_uCPU_Type Target station CPU Word 0000H, 03D0H Specify the CPU type of the target station. 0
type [Unsigned]/Bit to 03D3H, • 0000H: To CPU of target station (control CPU)
String [16-bit] 03E0H to • 03D0H: To control system CPU
03E3H, 03FFH • 03D1H: To standby system CPU
• 03D2H: To system A CPU
• 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(13) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if 5
ax resends [Unsigned]/Bit the data transfer is not completed within the
String [16-bit] monitoring time specified by "Arrival monitoring
time".
• 0 to 15
(14) pbi_uTimeUnit Arrival monitoring Word 0, 1 Specify the unit of the "Arrival monitoring time". 0
time unit [Unsigned]/Bit • 0: 1s
String [16-bit] • 1: 100ms
(15) pbi_uMonitorTime Arrival monitoring Word Specify the monitoring time until completion of 0
time (Ethernet) [Unsigned]/Bit processing.
String [16-bit] If "Arrival monitoring time unit" is set to 1s, specify
the TCP resend timer value or a greater value for
the monitoring time until completion of processing.
If the processing is not completed within the
monitoring time, data is resent until the value
specified in "Maximum number of resends" is
reached.
• 0 to TCP resend timer value: Time represented
by "TCP resend timer value"
• Effective range ("TCP resend timer value" + 1)
to 16383: ("TCP resend timer value" + 1)
seconds to 16383s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
Arrival monitoring Specify the monitoring time until completion of 0: 10s
time (CC-Link IE processing. If the processing is not completed
Controller Network, within the monitoring time, data is resent until the
CC-Link IE Field value specified in "Maximum number of resends"
Network, is reached.
MELSECNET/H) When "Arrival monitoring time unit" is set to 1s
• Effective range 1 to 32767: 1s to 32767s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
2 Ethernet-EQUIPPED MODULE FB
2.1 M+model_DeviceRead 17
No. Variable name Name Data type Range Description Default
value
(16) pbi_bStationSpecific Target station Bit On or off Specify the specification method of a target station. Off
address specification • Off: Use the network number and station
method number.
• On: Use the IP address (IPv4). (Ethernet only).
■Public variables
No. Variable name Name Data type Description Default
value
(17) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(18) pbo_u4ErrTime Error occurrence Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
time String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(19) pbo_uErrNetworkNo Error detection Word [Unsigned]/Bit The network number of the station in which an error was detected 0
network number String [16-bit] is stored.
(20) pbo_uErrStationNo Error-detected Word [Unsigned]/Bit The station number of the station in which an error was detected is 0
station number String [16-bit] stored.
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent device
station, submaster station
Station number of MELSECNET/H
• 1 to 64
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part)
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 85 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function reads device data from another station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
2 Ethernet-EQUIPPED MODULE FB
18 2.1 M+model_DeviceRead
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
2
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.1 M+model_DeviceRead 19
2.2 M+model_DeviceWrite
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_DeviceWrite RJ71EN71(E+E)
M+RJ71EN71_C_DeviceWrite RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_DeviceWrite RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_DeviceWrite RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_DeviceWrite RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_DeviceWrite
■RJ71GF11-T2
M+RJ71GF11_DeviceWrite
■RJ71LP21-25
M+RJ71LP21_DeviceWrite
■RJ71BR11
M+RJ71BR11_DeviceWrite
Overview
Item Description
Overview Writes data by specifying a device in the programmable controller of another station.
Symbol
M+RJ71GF11_DeviceWrite
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_u2TargetAddress o_bErr: B (10)
(4) UW: i_uDataLength o_uErrId: UW (11)
(5) UW: i_uWriteData
(6) S: i_s32TargetDevice
(7) UW: i_uChannel
pbi_uCPU_Type (12)
pbi_uTargetStation (13)
pbi_bArrivalConfirm (14)
pbi_uResendCountMax (15)
pbi_uTimeUnit (16)
pbi_uMonitorTime (17)
pbi_bStationSpecific (18)
pbo_uResendCount (19)
pbo_u4ErrTime (20)
pbo_uErrNetworkNo (21)
pbo_uErrStationNo (22)
2 Ethernet-EQUIPPED MODULE FB
20 2.2 M+model_DeviceWrite
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
2
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_u2TargetAddress Target station Word Specify the network number and station number of the target station when
address [Unsigned]/ "Target station address specification method" is off. When specifying the
Bit String numbers using a label, use an array as the data type.
[16-bit] ■When "Target station specification method" is set to 0 to specify a station
(0..1) number
• 1st word: Network number (1 to 239)
• 2nd word: Station number
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
■When "Target station specification method" is set to 1 to specify a group
• 1st word: Network number (1 to 239)
• 2nd word: Transient transmission group number (1 to 32)
■When "Target station specification method" is set to 2 to specify all
stations
• 1st word: Network number (1 to 239)
• 2nd word: 0 (The setting is ignored.)
Specify the IP address of the target station when "Target station address
specification method" is on (Ethernet only). Specify the third and fourth
octets to the 1st word, and first and second octets to the 2nd word. When
specifying the address using a label, use an array as the data type.
• 00000001H to FFFFFFFEH
Note that the fourth octet cannot be set to 0 or 255 (FFH).
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uDataLength Write data length Word Specify the number of words to be written.
[Unsigned]/ • When writing to RCPU, QCPU, or LCPU: 1 to 8192 words
Bit String • When writing to QnACPU: 1 to 480 words
[16-bit] When specifying 961 words or more, specify 9 or 10 in "Own station
channel".
(5) i_uWriteData Write data storage Word Specify the start device of own station containing the write data.
device [Unsigned]/ The following cannot be specified as an argument. Specifying any of the
Bit String following may cause a CPU error (2820H: Device/label/buffer memory
[16-bit] specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
(6) i_s32TargetDevice Target station write Character Specify the start device of the target station to which data is to be written.
device string (32) The following cannot be specified as an argument. Specifying any of the
following may cause a CPU error (2820H: Device/label/buffer memory
specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
2 Ethernet-EQUIPPED MODULE FB
2.2 M+model_DeviceWrite 21
No. Variable name Name Data type Range Description
(7) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(8) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(9) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(10) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(11) o_uErrId Error code Word [Unsigned]/ An error code is stored at error completion. 0
Bit String [16-bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(12) pbi_uCPU_Type Target station CPU Word 0000H, Specify the CPU type of the target station. 0
type [Unsigned]/ 03D0H to • 0000H: To CPU of target station (control CPU)
Bit String 03D3H, • 03D0H: To control system CPU
[16-bit] 03E0H to • 03D1H: To standby system CPU
03E3H, • 03D2H: To system A CPU
03FFH • 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(13) pbi_uTargetStation Target station Word 0 to 2 Specify the specification method of a target station. 0
specification method [Unsigned]/ • 0: Station number specification Station with the station
Bit String number specified in "Target station address"
[16-bit] • 1: Group specification (only when "OFF (No)" is specified
in "Arrival acknowledgment") All stations of the
transient transmission group number specified in "Arrival
station address" (For the CC-Link IE Field Network, the
value 1 cannot be specified.)
• 2: All stations (only when "OFF (No)" is specified in
"Arrival acknowledgment") All stations of the network
number specified in "Arrival station address" (broadcast
excluding own station)
2 Ethernet-EQUIPPED MODULE FB
22 2.2 M+model_DeviceWrite
No. Variable name Name Data type Range Description Default
value
(14) pbi_bArrivalConfirm Arrival Bit On or off Specify whether to use arrival acknowledgment. Off
acknowledgment ■Off: No check
• When the target station is within the own network,
sending data from the own station completes the
sending.
2
(1)
Es Ts
(1) Completion
Es: Execution source
Ts: Target station
• When the target station is within another network, data
arrival to the relay station within the own network
completes the sending.
(1)
Es Rs Ts
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
■On: Check
Sending data is completed when the data is written to the
target station.
(1)
Ts Es Rs Ts
(1)
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
(15) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String specified by "Arrival monitoring time".
[16-bit] • 0 to 15
(16) pbi_uTimeUnit Arrival monitoring Word 0, 1 Specify the unit of the "Arrival monitoring time". 0
time unit [Unsigned]/ • 0: 1s
Bit String • 1: 100ms
[16-bit]
(17) pbi_uMonitorTime Arrival monitoring Word Specify the monitoring time until completion of processing. 0
time (Ethernet) [Unsigned]/ If "Arrival monitoring time unit" is set to 1s, specify the TCP
Bit String resend timer value or a greater value for the monitoring
[16-bit] time until completion of processing. If the processing is not
completed within the monitoring time, data is resent until
the value specified in "Maximum number of resends" is
reached.
• 0 to TCP resend timer value: Time represented by "TCP
resend timer value"
• Effective range ("TCP resend timer value" + 1) to 16383:
("TCP resend timer value" + 1) seconds to 16383s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
Arrival monitoring Specify the monitoring time until completion of processing. 0: 10s
time (CC-Link IE If the processing is not completed within the monitoring
Controller Network, time, data is resent until the value specified in "Maximum
CC-Link IE Field number of resends" is reached.
Network, When "Arrival monitoring time unit" is set to 1s
MELSECNET/H) • Effective range 1 to 32767: 1s to 32767s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
(18) pbi_bStationSpecific Target station Bit On or off Specify the specification method of a target station. Off
address specification • Off: Use the network number and station number.
method • On: Use the IP address (IPv4). (Ethernet only).
2 Ethernet-EQUIPPED MODULE FB
2.2 M+model_DeviceWrite 23
■Public variables
No. Variable name Name Data type Description Default
value
(19) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(20) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H
(Saturday))
(21) pbo_uErrNetworkNo Error detection network Word [Unsigned]/Bit The network number of the station in which an error was 0
number String [16-bit] detected is stored.
(22) pbo_uErrStationNo Error-detected station Word [Unsigned]/Bit The station number of the station in which an error was 0
number String [16-bit] detected is stored.
Station number of Ethernet or CC-Link IE Controller
Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent
device station, submaster station
Station number of MELSECNET/H
• 1 to 64
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part)
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 90 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function writes device data to another station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
2 Ethernet-EQUIPPED MODULE FB
24 2.2 M+model_DeviceWrite
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
2
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.2 M+model_DeviceWrite 25
2.3 M+model_Send
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_Send RJ71EN71(E+E)
M+RJ71EN71_C_Send RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_Send RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_Send RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_Send RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_Send
■RJ71GF11-T2
M+RJ71GF11_Send
■RJ71LP21-25
M+RJ71LP21_Send
■RJ71BR11
M+RJ71BR11_Send
Overview
Item Description
Overview Sends data to the programmable controller of another station.
Symbol
M+RJ71GF11_Send
(1) B: i_bEN o_bENO: B (9)
(2) DUT: i_stModule o_bOK: B (10)
(3) UW: i_uTargetNetworkNo o_bErr: B (11)
(4) UW: i_uTargetStationNo o_uErrId: UW (12)
(5) UW: i_uChannel
(6) UW: i_uTargetChannel
(7) UW: i_uDataLength
(8) UW: i_uSendData
pbi_uTargetStation (13)
pbi_bArrivalConfirm (14)
pbi_uResendCountMax (15)
pbi_uMonitorTime (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrNetworkNo (19)
pbo_uErrStationNo (20)
2 Ethernet-EQUIPPED MODULE FB
26 2.3 M+model_Send
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
2
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_uTargetNetworkNo Target network Word 1 to 239 Specify the network number of the target station.
number [Unsigned]/
Bit String
[16-bit]
(4) i_uTargetStationNo Target station Word Specify the station number of the target station or the transient
number [Unsigned]/ transmission group number.
Bit String ■When "Target station specification method" is set to 0 to specify a
[16-bit] station number
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
■When "Target station specification method" is set to 1 to specify a
group
Specify the transient transmission group number.
• 1 to 32
■When "Target station specification method" is set to 2 to specify all
stations
The setting is ignored.
(5) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String Instructions)
[16-bit]
(6) i_uTargetChannel Target station data Word 1 to 8 Specify the channel of the target station for storing data.
storage channel [Unsigned]/ When the target station is a CC-Link IE Field Network master/local
Bit String module, specify 1 or 2.
[16-bit]
(7) i_uDataLength Send data length Word Specify the number of words to be sent.
[Unsigned]/ • When the target station is RCPU, QCPU, or LCPU: 1 to 960 words
Bit String • When the target station is QnACPU: 1 to 480 words
[16-bit]
(8) i_uSendData Send data storage Word Specify the start device of own station containing the send data.
device [Unsigned]/ The following cannot be specified as an argument. Specifying any of the
Bit String following may cause a CPU error (2820H: Device/label/buffer memory
[16-bit] specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
■Output arguments
No. Variable name Name Data type Description Default
value
(9) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(10) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(11) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(12) o_uErrId Error code Word [Unsigned]/Bit An error code is stored at error completion. 0
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
2.3 M+model_Send 27
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(13) pbi_uTargetStation Target station Word 0 to 2 Specify the specification method of a target station. 0
specification method [Unsigned]/ • 0: Station number specification Station with the station
Bit String [16- number specified in "Target station number"
bit] • 1: Group specification (only when "OFF (No)" is specified
in "Arrival acknowledgment") All stations of the
transient transmission group number specified in "Target
station number" (For the CC-Link IE Field Network, the
value 1 cannot be specified.)
• 2: All stations (only when "OFF (No)" is specified in
"Arrival acknowledgment") All stations of the network
number specified in "Target network number" (broadcast
excluding own station)
(14) pbi_bArrivalConfirm Arrival Bit On or off Specify whether to use arrival acknowledgment. Off
acknowledgment ■Off: No check
• When the target station is within the own network,
sending data from the own station completes the
sending.
(1)
Es Ts
(1) Completion
Es: Execution source
Ts: Target station
• When the target station is within another network, data
arrival to the relay station within the own network
completes the sending.
(1)
Es Rs Ts
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
■On: Check
Sending data is completed when the data is written to the
target station.
(1)
Ts Es Rs Ts
(1)
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
(15) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String [16- specified by "Arrival monitoring time".
bit] • 0 to 15
(16) pbi_uMonitorTime Arrival monitoring Word 0 to 16383 Specify the TCP resend timer value or a greater value for 0
time (Ethernet) [Unsigned]/ the monitoring time until completion of processing. If the
Bit String [16- processing is not completed within the monitoring time,
bit] data is resent until the value specified in "Maximum
number of resends" is reached.
• 0 to TCP resend timer value: Time represented by "TCP
resend timer value"
• ("TCP resend timer value" + 1) to 16383: ("TCP resend
timer value" + 1) seconds to 16383s
Arrival monitoring 0, 1 to Specify the monitoring time until completion of processing. 0
time (CC-Link IE 32767 If the processing is not completed within the monitoring
Controller Network, time, data is resent until the value specified in "Maximum
CC-Link IE Field number of resends" is reached.
Network, • 0: 10s
MELSECNET/H) • 1 to 32767: 1 to 32767s
2 Ethernet-EQUIPPED MODULE FB
28 2.3 M+model_Send
■Public variables
No. Variable name Name Data type Description Default
value
(17) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(18) pbo_u4ErrTime Error occurrence
time
Word [Unsigned]/Bit
String [16-bit] (0..3)
Clock data at the time of error occurrence is stored.
1st word
0
2
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(19) pbo_uErrNetworkNo Error detection Word [Unsigned]/Bit The network number of the station in which an error was detected 0
network number String [16-bit] is stored.
(20) pbo_uErrStationNo Error-detected Word [Unsigned]/Bit The station number of the station in which an error was detected 0
station number String [16-bit] is stored.
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent device
station, submaster station
Station number of MELSECNET/H
• 1 to 64
2 Ethernet-EQUIPPED MODULE FB
2.3 M+model_Send 29
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part)
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 75 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function sends a message to another station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
2 Ethernet-EQUIPPED MODULE FB
30 2.3 M+model_Send
Item Description
Precautions • This FB does not include error recovery processing. Please create error recovery processing separately according to the system and
required operations.
• This FB uses the GP.SEND instruction.
• Turn off i_bEN (execution command) after o_bOK (normal completion) or o_bErr (error completion) is turned on. By turning off i_bEN
(execution command), o_bOK (normal completion) or o_bErr (error completion) is turned off and o_uErrId (error code) is cleared to 0.
• This FB uses the label initial value by each program. When the program file using this FB is specified to boot file setting for the boot
operation in the CPU module, specify the initial label value file by each program to the boot file setting as well. ( MELSEC iQ-R CPU 2
Module User's Manual (Application)) If an error code that is not described in Page 31 Error codes appears, the initial label value files by
each program may not be set to the boot file setting. In this case, specify the initial label value files by each program to the boot file
setting.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.3 M+model_Send 31
2.4 M+model_Recv
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_Recv RJ71EN71(E+E)
M+RJ71EN71_C_Recv RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_Recv RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_Recv RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_Recv RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_Recv
■RJ71GF11-T2
M+RJ71GF11_Recv
■RJ71LP21-25
M+RJ71LP21_Recv
■RJ71BR11
M+RJ71BR11_Recv
Overview
Item Description
Overview Reads the data received from the programmable controller of another station.
Symbol
M+RJ71GF11_Recv
(1) B: i_bEN o_bENO: B (4)
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uRecvChannel o_bErr: B (6)
o_uErrId: UW (7)
o_uRecvDataLength: UW (8)
o_uRecvData: UW (9)
pbi_bReadTiming (10)
pbi_uMonitorTime (11)
pbo_uResendCount (12)
pbo_u4ErrTime (13)
pbo_uErrNetworkNo (14)
pbo_uErrStationNo (15)
pbo_uSendNetworkNo (16)
pbo_uSendStationNo (17)
pbo_uSendChannel (18)
2 Ethernet-EQUIPPED MODULE FB
32 2.4 M+model_Recv
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
2
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_uRecvChannel Receive data storage Word Specify the channel containing the data to be read.
channel [Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String [16- Instructions)
bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
(8) o_uRecvDataLength Receive data length Word The number of received data is stored. 0
[Unsigned]/Bit • 1 to 960 words
String [16-bit]
(9) o_uRecvData Receive data storage Word Specify the start number of the device for storing received data. 0
device [Unsigned]/Bit The following cannot be specified as an argument. Specifying any of the
String [16-bit] following may cause a CPU error (2820H: Device/label/buffer memory
specification incorrect).
• Dynamically specified array elements (Example: wLabel[D0])
• Digit-specified labels (Example: K4bLabel)
• Indirectly specified devices (Example: @W0)
• Local devices (Example: #D0)
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_bReadTiming Read timing Bit On Specify the timing of executing data read processing. On
• On: Start reading in the first END processing after the
module FB starts.
(11) pbi_uMonitorTime Arrival monitoring Word 0 to 16383 Specify the TCP resend timer value or a greater value for 0
time (Ethernet) [Unsigned]/ the monitoring time until completion of processing (the
Bit String setting is valid only when "Read timing" is on). When the
[16-bit] processing is not completed normally within the monitoring
time, the processing is completed with an error.
• 0 to TCP resend timer value: Time represented by "TCP
resend timer value"
• ("TCP resend timer value" + 1) to 16383: ("TCP resend
timer value" + 1) seconds to 16383s
Arrival monitoring 0, 1 to Specify the monitoring time until completion of processing 0
time (CC-Link IE 32767 (the setting is valid only when "Read timing" is on). When
Controller Network, the processing is not completed normally within the
CC-Link IE Field monitoring time, the processing is completed with an error.
Network, • 0: 10s
MELSECNET/H) • 1 to 32767: 1 to 32767s
2 Ethernet-EQUIPPED MODULE FB
2.4 M+model_Recv 33
■Public variables
No. Variable name Name Data type Description Default
value
(12) pbo_uResendCount Number of resends Word The number of resends performed (result) is stored. 0
[Unsigned]/
Bit String
[16-bit]
(13) pbo_u4ErrTime Error occurrence Word Clock data at the time of error occurrence is stored. 0
time [Unsigned]/ 1st word
Bit String • Upper 8 bits: Month (01H to 12H)
[16-bit] (0..3) • Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(14) pbo_uErrNetworkNo Error detection Word The network number of the station in which an error was detected is 0
network number [Unsigned]/ stored.
Bit String
[16-bit]
(15) pbo_uErrStationNo Error-detected Word The station number of the station in which an error was detected is stored. 0
station number [Unsigned]/ Station number of Ethernet or CC-Link IE Controller Network
Bit String • 1 to 120
[16-bit] Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
(16) pbo_uSendNetwork Send station network Word The network number of the send station is stored. 0
No number [Unsigned]/
Bit String
[16-bit]
(17) pbo_uSendStationN Send station number Word The station number of the send station is stored. 0
o [Unsigned]/ Station number of Ethernet or CC-Link IE Controller Network
Bit String • 1 to 120
[16-bit] Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
(18) pbo_uSendChannel Channel used by Word The channel number used by the send station is stored. 0
send station [Unsigned]/ 1 to 8
Bit String
[16-bit]
2 Ethernet-EQUIPPED MODULE FB
34 2.4 M+model_Recv
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part) 2
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 94 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function receives a message from another station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
2 Ethernet-EQUIPPED MODULE FB
2.4 M+model_Recv 35
Item Description
Precautions • This FB does not include error recovery processing. Please create error recovery processing separately according to the system and
required operations.
• This FB uses the GP.RECV instruction.
• Turn off i_bEN (execution command) after o_bOK (normal completion) or o_bErr (error completion) is turned on. By turning off i_bEN
(execution command), o_bOK (normal completion) or o_bErr (error completion) is turned off and o_uErrId (error code) is cleared to 0.
• This FB uses the label initial value by each program. When the program file using this FB is specified to boot file setting for the boot
operation in the CPU module, specify the initial label value file by each program to the boot file setting as well. ( MELSEC iQ-R CPU
Module User's Manual (Application)) If an error code that is not described in Page 36 Error codes appears, the initial label value files by
each program may not be set to the boot file setting. In this case, specify the initial label value files by each program to the boot file
setting.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
36 2.4 M+model_Recv
2.5 M+model_RemoteStopRun
Name
■RJ71EN71, RnENCPU (network part) 2
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_RemoteStopRun RJ71EN71(E+E)
M+RJ71EN71_C_RemoteStopRun RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_RemoteStopRun RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_RemoteStopRun RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_RemoteStopRun RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_RemoteStopRun
■RJ71GF11-T2
M+RJ71GF11_RemoteStopRun
■RJ71LP21-25
M+RJ71LP21_RemoteStopRun
■RJ71BR11
M+RJ71BR11_RemoteStopRun
Overview
Item Description
Overview Sends a remote STOP/RUN request to the programmable controller of another station.
Symbol
M+RJ71GF11_RemoteStopRun
(1) B: i_bEN o_bENO: B (7)
(2) DUT: i_stModule o_bOK: B (8)
(3) UW: i_uTargetNetworkNo o_bErr: B (9)
(4) UW: i_uTargetStationNo o_uErrId: UW (10)
(5) UW: i_uChannel
(6) UW: i_uRemoteType
pbi_uCPU_Type (11)
pbi_uTargetStation (12)
pbi_uForciblyRun (13)
pbi_uDeviceClear (14)
pbi_uResendCountMax (15)
pbi_uMonitorTime (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrNetworkNo (19)
pbo_uErrStationNo (20)
2 Ethernet-EQUIPPED MODULE FB
2.5 M+model_RemoteStopRun 37
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_uTargetNetworkNo Target network Word 1 to 239 Specify the network number of the target station.
number [Unsigned]/
Bit String [16-
bit]
(4) i_uTargetStationNo Target station Word Specify the station number of the target station or the transient
number [Unsigned]/ transmission group number.
Bit String [16- ■When "Target station specification method" is set to 0 to specify a
bit] station number
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
■When "Target station specification method" is set to 1 to specify a
group
Specify the transient transmission group number.
• 1 to 32
■When "Target station specification method" is set to 2 to specify all
stations
The setting is ignored.
(5) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String [16- Instructions)
bit]
(6) i_uRemoteType Remote operation Word 1, 2 Specify remote RUN or STOP.
[Unsigned]/ • 1: Remote RUN
Bit String [16- • 2: Remote STOP
bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(7) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(8) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(9) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(10) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
38 2.5 M+model_RemoteStopRun
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(11) pbi_uCPU_Type Target station CPU Word 0000H, 03D0H Specify the CPU type of the target station. 0
type [Unsigned]/Bit to 03D3H, • 0000H: To CPU of target station (control CPU)
String [16-bit] 03E0H to • 03D0H: To control system CPU
03E3H, 03FFH • 03D1H: To standby system CPU 2
• 03D2H: To system A CPU
• 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(12) pbi_uTargetStation Target station Word 0 to 2 Specify the specification method of a target station. 0
specification method [Unsigned]/Bit • 0: Station number specification Station with the
String [16-bit] station number specified in "Target station
number"
• 1: Group specification All stations of the
transient transmission group number specified in
"Target station number" (For the CC-Link IE Field
Network, the value 1 cannot be specified.)
• 2: All stations All stations of the network
number specified in "Target network number"
(simultaneous broadcast except own station)
(13) pbi_uForciblyRun Specification of Word 1, 2 ■"Remote operation": 1 (remote RUN) 1
forced remote RUN [Unsigned]/Bit Specify whether to forcibly execute remote RUN.
String [16-bit] The forcible execution function enables forcible
execution of remote RUN from another station
when a station which executed remote STOP can
no longer execute remote RUN.
• 1: Not forcibly executed
• 2: Forcibly executed
■"Remote operation": 2 (remote STOP)
Any setting here is ignored and the following setting
is always used.
• 2: Forcibly executed
(14) pbi_uDeviceClear Specification of Word 0 to 2 ■"Remote operation": 1 (remote RUN) 0
device clear at [Unsigned]/Bit Specify how to handle the CPU module device
remote RUN String [16-bit] memory after remote RUN is executed.
• 0: Do not clear.
• 1: Clear (except the latch range).
• 2: Clear (including the latch range).
■"Remote operation": 2 (remote STOP)
Any setting here is ignored.
(15) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if 5
ax resends [Unsigned]/Bit the data transfer is not completed within the
String [16-bit] monitoring time specified by "Arrival monitoring
time".
(16) pbi_uMonitorTime Arrival monitoring Word 0 to 16383 Specify the TCP resend timer value or a greater 0
time (Ethernet) [Unsigned]/Bit value for the monitoring time until completion of
String [16-bit] processing. If the processing is not completed
within the monitoring time, data is resent until the
value specified in "Maximum number of resends" is
reached.
• 0 to TCP resend timer value: Time represented
by "TCP resend timer value"
• ("TCP resend timer value" + 1) to 16383: ("TCP
resend timer value" + 1) seconds to 16383s
Arrival monitoring 0, 1 to 32767 Specify the monitoring time until completion of 0
time (CC-Link IE processing. If the processing is not completed
Controller Network, within the monitoring time, data is resent until the
CC-Link IE Field value specified in "Maximum number of resends" is
Network, reached.
MELSECNET/H) • 0: 10s
• 1 to 32767: 1 to 32767s
2 Ethernet-EQUIPPED MODULE FB
2.5 M+model_RemoteStopRun 39
■Public variables
No. Variable name Name Data type Description Default
value
(17) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(18) pbo_u4ErrTime Error occurrence Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
time String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(19) pbo_uErrNetworkNo Error detection Word [Unsigned]/Bit The network number of the station in which an error was 0
network number String [16-bit] detected is stored.
(20) pbo_uErrStationNo Error-detected Word [Unsigned]/Bit The station number of the station in which an error was 0
station number String [16-bit] detected is stored.
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, remote device station, intelligent
device station, submaster station
Station number of MELSECNET/H
• 1 to 64
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part)
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 122 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function performs remote STOP/RUN for other stations.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
2 Ethernet-EQUIPPED MODULE FB
40 2.5 M+model_RemoteStopRun
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
2
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.5 M+model_RemoteStopRun 41
2.6 M+model_ReadTime
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_ReadTime RJ71EN71(E+E)
M+RJ71EN71_C_ReadTime RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_ReadTime RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_ReadTime RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_ReadTime RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_ReadTime
■RJ71GF11-T2
M+RJ71GF11_ReadTime
■RJ71LP21-25
M+RJ71LP21_ReadTime
■RJ71BR11
M+RJ71BR11_ReadTime
Overview
Item Description
Overview Reads clock data from the programmable controller of another station to adjust the time of the programmable controller CPU of own
station.
Symbol
M+RJ71GF11_ReadTime
(1) B: i_bEN o_bENO: B (6)
(2) DUT: i_stModule o_bOK: B (7)
(3) UW: i_uTargetNetworkNo o_bErr: B (8)
(4) UW: i_uTargetStationNo o_uErrId: UW (9)
(5) UW: i_uChannel
pbi_uCPU_Type (10)
pbi_uResendCountMax (11)
pbi_uMonitorTime (12)
2 Ethernet-EQUIPPED MODULE FB
42 2.6 M+model_ReadTime
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
2
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_uTargetNetworkNo Target network Word 1 to 239 Specify the network number of the target station.
number [Unsigned]/
Bit String
[16-bit]
(4) i_uTargetStationNo Target station number Word Specifies the station number of the target station.
[Unsigned]/ Station number of Ethernet or CC-Link IE Controller Network
Bit String • 1 to 120
[16-bit] Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
(5) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String Instructions)
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(6) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(7) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(8) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(9) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
2.6 M+model_ReadTime 43
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uCPU_Type Target station CPU Word 0000H, 03D0H Specify the CPU type of the target station. 0
type [Unsigned]/Bit to 03D3H, • 0000H: To CPU of target station (control CPU)
String [16-bit] 03E0H to • 03D0H: To control system CPU
03E3H, 03FFH • 03D1H: To standby system CPU
• 03D2H: To system A CPU
• 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(11) pbi_uResendCountMax Maximum number Word 0 to 15 Specify the number of resends to be performed if 5
of resends [Unsigned]/Bit the data transfer is not completed within the
String [16-bit] monitoring time specified by "Arrival monitoring
time".
(12) pbi_uMonitorTime Arrival monitoring Word 0 to 16383 Specify the TCP resend timer value or a greater 0
time (Ethernet) [Unsigned]/Bit value for the monitoring time until completion of
String [16-bit] processing. If the processing is not completed
within the monitoring time, data is resent until the
value specified in "Maximum number of resends"
is reached.
• 0 to TCP resend timer value: Time represented
by "TCP resend timer value"
• ("TCP resend timer value" + 1) to 16383: ("TCP
resend timer value" + 1) seconds to 16383s
Arrival monitoring 0, 1 to 32767 Specify the monitoring time until completion of 0
time (CC-Link IE processing. If the processing is not completed
Controller Network, within the monitoring time, data is resent until the
CC-Link IE Field value specified in "Maximum number of resends"
Network, is reached.
MELSECNET/H) • 0: 10s
• 1 to 32767: 1 to 32767s
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part)
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 133 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function reads clock data from another station to adjust the time of the
programmable controller CPU of own station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
2 Ethernet-EQUIPPED MODULE FB
44 2.6 M+model_ReadTime
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
2
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.6 M+model_ReadTime 45
2.7 M+model_WriteTime
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_WriteTime RJ71EN71(E+E)
M+RJ71EN71_C_WriteTime RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_WriteTime RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_WriteTime RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_WriteTime RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_WriteTime
■RJ71GF11-T2
M+RJ71GF11_WriteTime
■RJ71LP21-25
M+RJ71LP21_WriteTime
■RJ71BR11
M+RJ71BR11_WriteTime
Overview
Item Description
Overview Writes the clock data of the programmable controller of own station to another station to adjust the time of the programmable controller
CPU of another station.
Symbol
M+RJ71GF11_WriteTime
(1) B: i_bEN o_bENO: B (6)
(2) DUT: i_stModule o_bOK: B (7)
(3) UW: i_uTargetNetworkNo o_bErr: B (8)
(4) UW: i_uTargetStationNo o_uErrId: UW (9)
(5) UW: i_uChannel
pbi_uCPU_Type (10)
pbi_uTargetStation (11)
pbi_uResendCountMax (12)
pbi_uMonitorTime (13)
2 Ethernet-EQUIPPED MODULE FB
46 2.7 M+model_WriteTime
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
2
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1,
LP21_1, BR11_1)
(3) i_uTargetNetworkNo Target network Word 1 to 239 Specify the network number of the target station.
number [Unsigned]/
Bit String
[16-bit]
(4) i_uTargetStationNo Target station Word Specify the station number of the target station or the transient
number [Unsigned]/ transmission group number.
Bit String ■When "Target station specification method" is set to 0 to specify a
[16-bit] station number
Station number of Ethernet or CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 126: Master operating station
• 1 to 120: Local station, remote device station, intelligent device station,
submaster station
Station number of MELSECNET/H
• 1 to 64
■When "Target station specification method" is set to 1 to specify a
group
Specify the transient transmission group number.
• 1 to 32
■When "Target station specification method" is set to 2 to specify all
stations
The setting is ignored.
(5) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String Instructions)
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(6) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(7) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(8) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(9) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
2.7 M+model_WriteTime 47
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uCPU_Type Target station CPU Word 0000H, 03D0H to Specify the CPU type of the target station. 0
type [Unsigned]/Bit 03D3H, 03E0H • 0000H: To CPU of target station (control CPU)
String [16-bit] to 03E3H, 03FFH • 03D0H: To control system CPU
• 03D1H: To standby system CPU
• 03D2H: To system A CPU
• 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(11) pbi_uTargetStation Target station Word 0 to 2 Specify the specification method of a target station. 0
specification method [Unsigned]/Bit • 0: Station number specification Station with
String [16-bit] the station number specified in "Target station
number"
• 1: Group specification All stations of the
transient transmission group number specified
in "Target station number" (For the CC-Link IE
Field Network, the value 1 cannot be specified.)
• 2: All stations All stations of the network
number specified in "Target network number"
(simultaneous broadcast except own station)
(12) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if 5
ax resends [Unsigned]/Bit the data transfer is not completed within the
String [16-bit] monitoring time specified by "Arrival monitoring
time".
(13) pbi_uMonitorTime Arrival monitoring Word 0 to 16383 Specify the TCP resend timer value or a greater 0
time (Ethernet) [Unsigned]/Bit value for the monitoring time until completion of
String [16-bit] processing. If the processing is not completed
within the monitoring time, data is resent until the
value specified in "Maximum number of resends"
is reached.
• 0 to TCP resend timer value: Time represented
by "TCP resend timer value"
• ("TCP resend timer value" + 1) to 16383: ("TCP
resend timer value" + 1) seconds to 16383s
Arrival monitoring 0, 1 to 32767 Specify the monitoring time until completion of 0
time (CC-Link IE processing. If the processing is not completed
Controller Network, within the monitoring time, data is resent until the
CC-Link IE Field value specified in "Maximum number of resends"
Network, is reached.
MELSECNET/H) • 0: 10s
• 1 to 32767: 1 to 32767s
2 Ethernet-EQUIPPED MODULE FB
48 2.7 M+model_WriteTime
FB details
Item Description
Available device Target module • RJ71GF11-T2
• RJ71GP21(S)-SX
• RJ71EN71
• RnENCPU (network part) 2
• RJ71LP21-25
• RJ71BR11
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 133 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function writes clock data to another station to adjust the time of the programmable
controller CPU of the station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
2 Ethernet-EQUIPPED MODULE FB
2.7 M+model_WriteTime 49
Item Description
Precautions • This FB does not include error recovery processing. Please create error recovery processing separately according to the system and
required operations.
• This FB uses the GP.REQ instruction.
• Turn off i_bEN (execution command) after o_bOK (normal completion) or o_bErr (error completion) is turned on. By turning off i_bEN
(execution command), o_bOK (normal completion) or o_bErr (error completion) is turned off and o_uErrId (error code) is cleared to 0.
• This FB uses the label initial value by each program. When the program file using this FB is specified to boot file setting for the boot
operation in the CPU module, specify the initial label value file by each program to the boot file setting as well. ( MELSEC iQ-R CPU
Module User's Manual (Application)) If an error code that is not described in Page 50 Error codes appears, the initial label value files by
each program may not be set to the boot file setting. In this case, specify the initial label value files by each program to the boot file
setting.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error codes
Error code Reference
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
6F00H to 6FFFH
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
F000H to FFFFH MELSEC iQ-R MELSECNET/H Network Module User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
50 2.7 M+model_WriteTime
2.8 M+model_ConnectionOpen
Name
■RJ71EN71, RnENCPU (network part) 2
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_ConnectionOpen RJ71EN71(E+E)
M+RJ71EN71_EC_ConnectionOpen RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_EF_ConnectionOpen RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
Overview
Item Description
Overview Opens (establishes) a connection.
Symbol
M+RCPU_ConnectionOpen
(1) B: i_bEN o_bENO: B (4)
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uConnectionNo o_bErr: B (6)
o_uErrId: UW (7)
pbi_bUseParameters 0 (8)
pbi_uProtocol 0 (9)
pbi_uOpen_System 0 (10)
pbi_uConnUsage 0 (11)
pbi_bProcedure 0 (12)
pbi_uExist_Confirm 0 (13)
pbi_uLocal_Port_No 4096 (14)
pbi_uTarget_Port_No 4096 (15)
pbi_u2IP_Address 0 (16)
pbi_bEnable_Online_Change 0 (17)
pbi_bData_Code 0 (18)
2 Ethernet-EQUIPPED MODULE FB
2.8 M+model_ConnectionOpen 51
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, RCPU)
(3) i_uConnectionNo Connection No. Word • RCPU (CPU part for the Specify the number of the connection to be
[Unsigned]/ RnENCPU): 1 to 16 opened.
Bit String • RJ71EN71: 1 to 128
[16-bit] • RnENCPU (network part): 1 to 64
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
52 2.8 M+model_ConnectionOpen
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(8) pbi_bUseParameters Parameter used Bit On or off Specify whether to use the parameter values set by the Off
engineering tool or the following operation parameter
values when processing for opening a connection.
• Off: Performs open processing according to the external 2
device configuration setting made by the engineering
tool. (The following operation parameters need not be
set. Any settings are ignored if made.)
• On: Performs open processing according to the following
operation parameters.
(9) pbi_uProtocol Protocol Word 0, 1 Select the protocol to be used for the connection to be 0
[Unsigned]/ opened.
Bit String • 0: TCP/IP
[16-bit] • 1: UDP/IP
(10) pbi_uOpen_System Open method Word 0 to 2 Select the connection open method. 0
[Unsigned]/ • 0: Active open or UDP/IP
Bit String • 1: Unpassive open
[16-bit] • 2: Fullpassive open
(11) pbi_uConnUsage Connection use Word 0 to 2 Specify the purpose of the connection: sending, receiving, 0
application [Unsigned]/ or pairing open with regard to the external device.
Bit String • 0: Send
[16-bit] • 1: Receive
• 2: Pairing open (The value 2 can be set for the
connection No.1 to No.7 and No.9 to No.15.)
Valid only when connection No.1 to 16 is used with the
RJ71EN71 or the RnENCPU (network part).
For the RCPU (CPU part for the RnENCPU), the setting is
ignored because it does not support communications using
a fixed buffer.
(12) pbi_bProcedure Communication Bit On or off Specify whether to use a communication procedure. Off
procedure • Off: Procedure not used
• On: Procedure used
Valid only when connection No.1 to 16 is used with the
RJ71EN71 or the RnENCPU (network part).
For the RCPU (CPU part for the RnENCPU), the setting is
ignored because it does not support communications using
a fixed buffer.
(13) pbi_uExist_Confirm Alive check Word 0 to 2 Specify whether to enable the arrive check function (with 0
[Unsigned]/ the use mode).
Bit String • 0: Disable the alive check.
[16-bit] • 1: Enable KeepAlive (in TCP/IP mode only).
• 2: Enable the alive check with UDP (in UDP/IP mode
only)
Valid only when connection No.1 to 16 is used with the
RJ71EN71 or the RnENCPU (network part).
For the RCPU (CPU part for the RnENCPU), the setting is
ignored because it does not support communications using
a fixed buffer.
(14) pbi_uLocal_Port_No Own node port Word 1 to 4999, Specify the port number of the own node. 4096
number [Unsigned]/ 5010 to Port numbers 1 to 1023 are generally reserved port
Bit String 65534 numbers (WELL KNOWN PORT NUMBERS), and
[16-bit] therefore port numbers 1024 to 4999 and 5010 to 65534
should be used.
(15) pbi_uTarget_Port_No Destination port Word 1 to Specify the destination port number. 4096
number [Unsigned]/ 65534, With the connection that is assigned port No.65535 (only
Bit String 65535 when the UDP/IP protocol is selected), data is received
[16-bit] through all port numbers. Data cannot be sent with the
connection which is assigned port No.65535 and therefore
a port number from 1 to 65534 should be specified to send
data.
2 Ethernet-EQUIPPED MODULE FB
2.8 M+model_ConnectionOpen 53
No. Variable name Name Data type Range Description Default
value
(16) pbi_u2IP_Address IP address of external Word 0.0.0.1 to Specify the IP address of an external device. 192.168.1.
device [Unsigned]/ 255.255.2 Specify the third and fourth octets to the 1st word, and first 1
Bit String 55.255 and second octets to the 2nd word. (C0A8010
[16-bit] (00000001 Specify 255.255.255.255 (FFFFFFFFH) when performing 1H)
(0..1) H to simultaneous broadcast.
FFFFFFFF
b15 b8 b7 b0
H)
+0 (3) (4)
+1 (1) (2)
FB details
Item Description
Available device Target module • RCPU (CPU part for the RnENCPU)
• RJ71EN71
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 171 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function opens (establishes) a connection for data communication with an external
device.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
2 Ethernet-EQUIPPED MODULE FB
54 2.8 M+model_ConnectionOpen
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
2
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.8 M+model_ConnectionOpen 55
2.9 M+model_ConnectionClose
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_ConnectionClose RJ71EN71(E+E)
M+RJ71EN71_EC_ConnectionClose RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_EF_ConnectionClose RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
Overview
Item Description
Overview Closes (disconnects) the connection.
Symbol
M+RCPU_ConnectionClose
(1) B: i_bEN o_bENO: B (4)
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uConnectionNo o_bErr: B (6)
o_uErrId: UW (7)
pbo_uErrConn_No 0 (8)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, RCPU)
(3) i_uConnectionNo Connection No. Word • RCPU (CPU part for the Specify the number of the connection to be closed.
[Unsigned]/ RnENCPU): 1 to 16 This function closes all connections if 65535
Bit String • RJ71EN71: 1 to 128 (FFFFH) is specified.
[16-bit] • RnENCPU (network part): 1 to 64
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word [Unsigned]/ An error code is stored at error completion. 0
Bit String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
56 2.9 M+model_ConnectionClose
■Public variables
No. Variable name Name Data type Description Default
value
(8) pbo_uErrConn_No Error connection Word [Unsigned]/ The number of the connection for which close processing was 0
No. Bit String [16-bit] completed with an error is stored.
If 65535 (FFFFH) is specified in "Connection No." (i_uConnectionNo),
the number of the connection for which close processing was first
completed with an error is stored.
2
FB details
Item Description
Available device Target module • RCPU (CPU part for the RnENCPU)
• RJ71EN71
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 86 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing • When i_bEN (execution command) is turned on, this function closes a connection for data communication with an external device.
• The function closes all connections if 65535 (FFFFH) is specified for "Connection No." (i_uConnectionNo) in the input argument.
• If the function fails to close even one connection among those specified to be closed, it is completed with an error.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
2 Ethernet-EQUIPPED MODULE FB
2.9 M+model_ConnectionClose 57
Item Description
Precautions • This module FB cannot be executed for the connection that is being used by another module FB or a dedicated instruction. An error
occurs if this module FB is executed for the connection in use.
• Turn off i_bEN (execution command) after o_bOK (normal completion) or o_bErr (error completion) is turned on. By turning off i_bEN
(execution command), o_bOK (normal completion) or o_bErr (error completion) is turned off and o_uErrId (error code) is cleared to 0.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
58 2.9 M+model_ConnectionClose
2.10 M+model_Recv_Socket
Name
■RJ71EN71, RnENCPU (network part) 2
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_Recv_Socket RJ71EN71(E+E)
M+RJ71EN71_EC_Recv_Socket RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_EF_Recv_Socket RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
Overview
Item Description
Overview Reads the data received from the external device through socket communications or fixed buffer communications.
Symbol
(1) M+RCPU_Recv_Socket o_bENO: B (4)
B: i_bEN
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uConnectionNo o_bErr: B (6)
o_uErrId: UW (7)
o_uRecvData: UW (8)
pbi_bReadTiming 0 (9)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, RCPU)
(3) i_uConnectionNo Connection No. Word • RCPU (CPU part for the Specify the number of the connection to be received.
[Unsigned]/ RnENCPU): 1 to 16
Bit String • RJ71EN71: 1 to 128
[16-bit] • RnENCPU (network part): 1 to 64
2 Ethernet-EQUIPPED MODULE FB
2.10 M+model_Recv_Socket 59
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
(8) o_uRecvData Receive data Word Specify the receive data length and the start number of the device for 0
storage destination [Unsigned]/Bit storing received data. The data that has been read is stored sequentially
String [16-bit] in ascending order of addresses as shown below.
• When the data unit is word
1st word: Receive data length (unit: word)
2nd to nth word: Receive data 1 to m
b15 b8 b7 b0
(2) (1)
·
(4) (3)
■Operation parameters
No. Variable name Name Data Range Description Default value
type
(9) pbi_bReadTiming Read timing Bit On or off Specify the timing of executing data read • RCPU (CPU part for the
processing. RnENCPU): Off
• Off: Start reading soon after the module FB • RJ71EN71, RnENCPU
starts. (network part): On
• On: Start reading in the first END processing
after the module FB starts.
FB details
Item Description
Available device Target module • RCPU (CPU part for the RnENCPU)
• RJ71EN71
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 109 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function reads the data received to the connection specified by the input argument.
2 Ethernet-EQUIPPED MODULE FB
60 2.10 M+model_Recv_Socket
Item Description
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Timing chart of I/O • For normal completion
signals
i_bEN 2
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
2.10 M+model_Recv_Socket 61
2.11 M+model_Send_Socket
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_Send_Socket RJ71EN71(E+E)
M+RJ71EN71_EC_Send_Socket RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_EF_Send_Socket RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
Overview
Item Description
Overview Sends data to the external device through socket communications or fixed buffer communications.
Symbol
(1) M+RCPU_Send_Socket o_bENO: B (5)
B: i_bEN
(2) DUT: i_stModule o_bOK: B (6)
(3) UW: i_uConnectionNo o_bErr: B (7)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, RCPU)
(3) i_uConnectionNo Connection No. Word • RCPU (CPU part for the Specify the number of the connection to be sent.
[Unsigned]/ RnENCPU): 1 to 16
Bit String • RJ71EN71: 1 to 128
[16-bit] • RnENCPU (network
part): 1 to 64
2 Ethernet-EQUIPPED MODULE FB
62 2.11 M+model_Send_Socket
No. Variable name Name Data type Range Description
(4) i_uSendData Send data storage Word Specify the send data length and the start number of the
destination [Unsigned]/ device containing the send data.*1
Bit String • When the data unit is word
[16-bit] 1st word: Send data length (unit: word)
2nd to nth word: Send data 1 to send data m
• When the data unit is byte
1st word: Send data length (unit: byte) 2
2nd to nth word:
b15 b8 b7 b0
(2) (1)
·
(4) (3)
*1 The data unit and the range of send data length differ depending on the communication method of parameters and communication data
code setting as follows.
■Output arguments
No. Variable name Name Data type Description Default
value
(5) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(6) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(7) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(8) o_uErrId Error code Word [Unsigned]/Bit An error code is stored at error completion. 0
String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
2.11 M+model_Send_Socket 63
FB details
Item Description
Available device Target module • RCPU (CPU part for the RnENCPU)
• RJ71EN71
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 60 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function sends the data to the external device of the connection specified by the
input argument.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
64 2.11 M+model_Send_Socket
2.12 M+model_Refresh_Data
Name
This FB is displayed as follows on the engineering tool depending on the settings.
2
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_EE_Refresh_Data RJ71EN71(E+E)
M+RJ71EN71_EC_Refresh_Data RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_EF_Refresh_Data RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
Overview
Item Description
Overview Transfers module label data.
Symbol
M+RCPU_Refresh_Data
(1) B: i_bEN o_bENO: B (3)
(2) DUT: i_stModule
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, RCPU)
■Output arguments
No. Variable name Name Data type Description Default value
(3) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
2 Ethernet-EQUIPPED MODULE FB
2.12 M+model_Refresh_Data 65
FB details
Item Description
Available device Target module • RJ71EN71
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 33 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function transfers the following buffer memory data of the RJ71EN71 or the
RnENCPU (network part) to the module label.
• Open completion signal (addresses 1900000 to 1900007)
• Open request signal (addresses 1900008 to 1900015)
• Socket/fixed buffer reception status signal (addresses 1900016 to 1900023)
FB compilation Macro type
method
FB operation ON-time execution type
Timing chart of I/O
signals i_bEN
o_bENO
Precautions When another FB is used, write the program so that scan is executed every time at the beginning of the program.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error code
This FB has no error code.
2 Ethernet-EQUIPPED MODULE FB
66 2.12 M+model_Refresh_Data
2.13 M+model_SLMP_DeviceRead_IP
Name
M+RCPU_SLMP_DeviceRead_IP
2
Overview
Item Description
Overview Reads data from the SLMP-compatible device specified by an IP address. The external device must support SLMP command (Device
Read).
Symbol
M+RCPU_SLMP_DeviceRead_IP
(1) B: i_bEN o_bENO: B (10)
(2) DUT: i_stModule o_bOK: B (11)
(3) UW: i_u2IP_Address o_bErr: B (12)
(4) UW: i_uSubCommand o_uErrId: UW (13)
(5) UW: i_uDeviceCode o_uReadData:UW (14)
pbi_uRequestModuleIO (15)
pbi_uResendCountMax (16)
pbi_uMonitorTime (17)
pbo_uResendCount (18)
pbo_u4ErrTime (19)
pbo_u2ErrIP_Address (20)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(3) i_u2IP_Address IP address of external Word [Unsigned]/Bit 0.0.0.1 to Specify the IP address of an external device.
device String [16-bit] (0..1) 255.255.255.254 Specify the third and fourth octets to the 1st word,
(00000001H to and first and second octets to the 2nd word.
FFFFFFFEH) Note that the fourth octet cannot be set to 0 or 255
(FFH).
b15 b8 b7 b0
+0 (3) (4)
+1 (1) (2)
2 Ethernet-EQUIPPED MODULE FB
2.13 M+model_SLMP_DeviceRead_IP 67
No. Variable name Name Data type Range Description
(5) i_uDeviceCode Device code*1 Word [Unsigned]/Bit Specify the device code of the device to be read in
String [16-bit] binary code.
• When the 1st bit of the subcommand is 0: 2 digits
• When the 1st bit of the subcommand is 1: 4 digits
(6) i_u2DeviceNo Head device No. Word [Unsigned]/Bit Specify the start device number of the device to be
String [16-bit] (0..1) read in binary code.
• When the 1st bit of the subcommand is 0: 6 digits
• When the 1st bit of the subcommand is 1: 8 digits
(7) i_uDevicePoints Number of device Word [Unsigned]/Bit Specify the number of device points of the device to
points String [16-bit] be read in binary code.
• When the 0th bit of the subcommand is 0: 1 to 960
• When the 0th bit of the subcommand is 1: 1 to
3972
(8) i_uChannel Own station channel Word [Unsigned]/Bit 1 to 9 Specify the channel to be used by the own station.
String [16-bit] Since whether or not a serial number*2 is given to the
request message depends on the channel, specify
the channel as follows according to the application.
• 1: No serial number is given
• 2 to 9: Serial number is given
(9) i_uTarget_Port_No Destination port Word [Unsigned]/Bit 1 to 65534 Specify the UDP port number of an external device.
number String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
68 2.13 M+model_SLMP_DeviceRead_IP
■Output arguments
No. Variable name Name Data type Description Default
value
(10) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(11) o_bOK Normal completion Bit The FB has been processed normally when this argument is
on.
Off
2
(12) o_bErr Error completion Bit The FB has been processed abnormally when this argument Off
is on.
(13) o_uErrId Error code Word [Unsigned]/Bit An error code is stored at error completion. 0
String [16-bit]
(14) o_uReadData Read data storage Word [Unsigned]/Bit Specify the start device number of the device for storing the 0
destination String [16-bit] read data. The read data is stored in binary code.
■When the 0th bit of the subcommand is 0
The device data is read in units of words.
Example: When reading the bit device M100 to M115 (one
word) in units of words
1st word:
b15 b8 b7 b0
1 2 3 4
0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0
M115 M100
D0
2nd word:
b15 b8 b7 b0
0 0 0 2
D1
3rd word:
b15 b8 b7 b0
1 D E F
D2
■When the 0th bit of the subcommand is 1
The device data is read in units of bits.
Example: When reading the bit device M100 to M107 in units
of bits
1st word:
b15 b8 b7 b0
0 1 0 0
M102 M103 M100 M101
2nd word:
b15 b8 b7 b0
1 1 0 0
2 Ethernet-EQUIPPED MODULE FB
2.13 M+model_SLMP_DeviceRead_IP 69
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(15) pbi_uRequestModuleIO Requested module I/ Word 03D0H to 03D3H, 03E0H to Specify the module of the access 03FFH
O No. [Unsigned]/ 03E3H, 03FFH destination.
Bit String [16- • 03D0H: Control system CPU
bit] • 03D1H: Standby system CPU
• 03D2H: System A CPU
• 03D3H: System B CPU
• 03FFH: Own station, control CPU
• 03E0H: Multiple CPU No.1
• 03E1H: Multiple CPU No.2
• 03E2H: Multiple CPU No.3
• 03E3H: Multiple CPU No.4
(16) pbi_uResendCountMax Maximum number of Word 0 to 15 Specify the number of resends to be 5
resends [Unsigned]/ performed if the data transfer is not
Bit String [16- completed within the monitoring
bit] time specified by pbi_uMonitorTime
(Arrival monitoring time).
• 0 to 15
(17) pbi_uMonitorTime Arrival monitoring Word 0, 1 to 32767 Specify the monitoring time until 0
time [Unsigned]/ completion of processing. If the
Bit String [16- processing is not completed within
bit] the monitoring time, data is resent
until the value specified in
pbi_uResendCountMax (Maximum
number of resends) is reached.
• 0: 10s
• 1 to 32767: 1 to 32767s
■Public variables
No. Variable name Name Data type Description Default
value
(18) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(19) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(20) pbo_u2ErrIP_Address Error-detected station Word [Unsigned]/Bit The IP address of the station in which an error was detected is 0
IP address String [16-bit] (0..1) stored.
The third and fourth octets are stored in the 1st word, and first
and second octets are stored in the 2nd word.
b15 b8 b7 b0
+0 (3) (4)
+1 (1) (2)
2 Ethernet-EQUIPPED MODULE FB
70 2.13 M+model_SLMP_DeviceRead_IP
FB details
Item Description
Available device Target module • RnCPU*1
• RnENCPU (CPU part)*1
CPU module • RnCPU*1
• RnENCPU*1 2
*2
Engineering tool GX Works3
Language Ladder diagram
Number of basic 190 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing • When i_bEN (execution command) is turned on, this function reads device data from the SLMP-compatible device.
• Execute this FB while the IP address for an external device is specified.
• This FB uses Read command (command: 0401) of the SLMP. The message of the SLMP command is a binary code. ( SLMP
Reference Manual)
FB compilation Macro type
method
FB operation ON-time execution type
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
2 Ethernet-EQUIPPED MODULE FB
2.13 M+model_SLMP_DeviceRead_IP 71
Item Description
Precautions • This FB does not include error recovery processing. Please create error recovery processing separately according to the system
and required operations.
• This FB uses the SLMPSND instruction.
• Turn off i_bEN (execution command) after o_bOK (normal completion) or o_bErr (error completion) is turned on. By turning off
i_bEN (execution command), o_bOK (normal completion) or o_bErr (error completion) is turned off and o_uErrId (error code) is
cleared to 0.
• In this FB, access devices (such as link direct device) that are accessed by the extension specification of the SLMP cannot be read.
• In this FB, stations in other network cannot be set as the target station.
• When this FB is executed for the port of an external device where the remote password is set, execute this FB after performing the
unlock processing of the remote password. When this FB is executed for the port of an external device where the remote password
is set, an error will occur.
• The target station must support "Read (command: 0401)" of the SLMP command.
• This FB is for communications in binary code only. (Communications using ASCII code cannot be performed.)
• This FB uses UDP communications. Set the protocol setting of the external device to UDP.
• This FB uses the label initial value by each program. When the program file using this FB is specified to boot file setting for the boot
operation in the CPU module, specify the initial label value file by each program to the boot file setting as well. ( MELSEC iQ-R
CPU Module User's Manual (Application)) If an error code that is not described in Page 72 Error codes appears, the initial label
value files by each program may not be set to the boot file setting. In this case, specify the initial label value files by each program to
the boot file setting.
• When this FB is executed, an operation error may occur in the programmable controller CPU. In this case, check the detailed
information of the operation error in event history and correct the input argument of the module FB.
Error codes
Error code Description Action
100H A value out of the range is set in the number of device points Set the value within the setting range in the number of device
(i_uDevicePoints) of the argument. points (i_uDevicePoints).
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
72 2.13 M+model_SLMP_DeviceRead_IP
2.14 M+model_SLMP_DeviceWrite_IP
Name
M+RCPU_SLMP_DeviceWrite_IP
2
Overview
Item Description
Overview Writes data to the SLMP-compatible device specified by an IP address. The external device must support SLMP command (Device Write).
Symbol
M+RCPU_SLMP_DeviceWrite_IP
(1) B: i_bEN o_bENO: B (11)
(2) DUT: i_stModule o_bOK: B (12)
(3) UW: i_u2IP_Address o_bErr: B (13)
(4) UW: i_uSubCommand o_uErrId: UW (14)
(5) UW: i_uDeviceCode
(6) UW: i_u2DeviceNo
(7) UW: i_uDevicePoints
(8) UW: i_uWriteData
(9) UW: i_uChannel
(10) UW: i_uTarget_Port_No
pbi_uRequestModuleIO (15)
pbi_uResendCountMax (16)
pbi_uMonitorTime (17)
pbo_uResendCount (18)
pbo_u4ErrTime (19)
pbo_u2ErrIP_Address (20)
2 Ethernet-EQUIPPED MODULE FB
2.14 M+model_SLMP_DeviceWrite_IP 73
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_u2IP_Address IP address of external Word [Unsigned]/Bit 0.0.0.1 to Specify the IP address of the target station.
device String [16-bit] (0..1) 255.255.255.254 Specify the third and fourth octets to the 1st word, and
(1H to first and second octets to the 2nd word.
FFFFFFFEH) Note that the fourth octet cannot be set to 0 or 255
(FFH).
b15 b8 b7 b0
+0 (3) (4)
+1 (1) (2)
2 Ethernet-EQUIPPED MODULE FB
74 2.14 M+model_SLMP_DeviceWrite_IP
No. Variable name Name Data type Range Description
(8) i_uWriteData Write data storage Word [Unsigned]/Bit Specify the start device number of the device for storing
destination String [16-bit] the write data.
■When the 0th bit of the subcommand is 0
The device data is written in units of words.
Example: When writing the bit device M100 to M115
(one word) in units of words
1st word: 2
b15 b8 b7 b0
1 2 3 4
0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0
M115 M100
Example: When writing the word device D0 to D2 in
units of words
1st word:
b15 b8 b7 b0
1 2 3 4
D0
2nd word:
b15 b8 b7 b0
0 0 0 2
D1
3rd word:
b15 b8 b7 b0
1 D E F
D2
■When the 0th bit of the subcommand is 1
The device data is written in units of bits.
Example: When writing the bit device M100 to M107 in
units of bits
1st word:
b15 b8 b7 b0
0 1 0 0
M102 M103 M100 M101
2nd word:
b15 b8 b7 b0
1 1 0 0
(9) i_uChannel Own station channel Word [Unsigned]/Bit 1 to 9 Specify the channel to be used by the own station.
String [16-bit] Since whether or not a serial number*2 is given to the
request message depends on the channel, specify the
channel as follows according to the application.
• 1: No serial number is given
• 2 to 9: Serial number is given
(10) i_uTarget_Port_No Destination port Word [Unsigned]/Bit 1 to 65534 Specify the UDP port number of an external device.
number String [16-bit]
2 Ethernet-EQUIPPED MODULE FB
2.14 M+model_SLMP_DeviceWrite_IP 75
■Output arguments
No. Variable name Name Data type Description Default
value
(11) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(12) o_bOK Normal completion Bit The FB has been processed normally when this argument is Off
on.
(13) o_bErr Error completion Bit The FB has been processed abnormally when this argument Off
is on.
(14) o_uErrId Error code Word [Unsigned]/Bit An error code is stored at error completion. 0
String [16-bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(15) pbi_uRequestModuleIO Requested module I/ Word 03D0H to 03D3H, 03E0H to Specify the module of the access 03FFH
O No. [Unsigned]/ 03E3H, 03FFH destination.
Bit String [16- • 03D0H: Control system CPU
bit] • 03D1H: Standby system CPU
• 03D2H: System A CPU
• 03D3H: System B CPU
• 03FFH: Own station, control
CPU
• 03E0H: Multiple CPU No.1
• 03E1H: Multiple CPU No.2
• 03E2H: Multiple CPU No.3
• 03E3H: Multiple CPU No.4
(16) pbi_uResendCountMax Maximum number of Word 0 to 15 Specify the number of resends to 5
resends [Unsigned]/ be performed if the data transfer is
Bit String [16- not completed within the
bit] monitoring time specified by
pbi_uMonitorTime (Arrival
monitoring time).
• 0 to 15
(17) pbi_uMonitorTime Arrival monitoring Word 0, 1 to 32767 Specify the monitoring time until 0
time [Unsigned]/ completion of processing. If the
Bit String [16- processing is not completed within
bit] the monitoring time, data is resent
until the value specified in
pbi_uResendCountMax (Maximum
number of resends) is reached.
• 0: 10s
• 1 to 32767: 1 to 32767s
2 Ethernet-EQUIPPED MODULE FB
76 2.14 M+model_SLMP_DeviceWrite_IP
■Public variables
No. Variable name Name Data type Description Default
value
(18) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(19) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit
String [16-bit] (0..3)
Clock data at the time of error occurrence is stored.
1st word
0
2
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(20) pbo_u2ErrIP_Address Error-detected station Word [Unsigned]/Bit The IP address of the station in which an error was detected is 0
IP address String [16-bit] (0..1) stored.
The third and fourth octets are stored in the 1st word, and first
and second octets are stored in the 2nd word.
b15 b8 b7 b0
+0 (3) (4)
+1 (1) (2)
FB details
Item Description
Available device Target module • RnCPU*1
• RnENCPU (CPU part)*1
CPU module • RnCPU*1
• RnENCPU*1
Engineering tool GX Works3*2
Language Ladder diagram
Number of basic 210 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing • When i_bEN (execution command) is turned on, this function writes device data of the SLMP-compatible device.
• Execute this FB while the IP address for an external device is specified.
• This FB uses Write command (command: 1401) of the SLMP. The message of the SLMP command is a binary code. ( SLMP
Reference Manual)
FB compilation Macro type
method
FB operation ON-time execution type
2 Ethernet-EQUIPPED MODULE FB
2.14 M+model_SLMP_DeviceWrite_IP 77
Item Description
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Description Action
100H A value out of the range is set in the number of device points Set the value within the setting range in the number of device
(i_uDevicePoints) of the argument. points (i_uDevicePoints).
C000H to CFFFH MELSEC iQ-R Ethernet User's Manual (Application)
2 Ethernet-EQUIPPED MODULE FB
78 2.14 M+model_SLMP_DeviceWrite_IP
3 CC-Link IE TSN MASTER/LOCAL MODULE FB
3.1 M+model_DeviceRead
Name
■RJ71GN11-T2 3
M+RJ71GN11_DeviceRead
■RJ71GN11-SX
M+RJ71GN11_SX_DeviceRead
■RJ71GN11-EIP
M+RJ71GN11_SE_DeviceRead
Overview
Item Description
Overview Reads data by specifying a device in the programmable controller of another station.
Symbol
M+RJ71GN11_DeviceRead
(1) B: i_bEN o_bENO: B (7)
(2) DUT: i_stModule o_bOK: B (8)
(3) UW: i_u2TargetAddress o_bErr: B (9)
(4) UW: i_uDataLength o_uErrId: UW (10)
(5) S: i_s32TargetDevice o_uReadData: UW (11)
(6) UW: i_uChannel
pbi_uCPU_Type (12)
pbi_uResendCountMax (13)
pbi_uTimeUnit (14)
pbi_uMonitorTime (15)
pbi_bStationSpecific (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrStationAddress1 (19)
pbo_uErrStationAddress2 (20)
Specify the IP address of the target station when "Target station address
specification method" is on. Specify the third and fourth octets to the 1st
word, and first and second octets to the 2nd word. When specifying the
address using a label, use an array as the data type.
• Ethernet, CC-Link IE TSN
00000001H to FFFFFFFEH
Specify a value within the range of 1 to 254 (FEH) for the fourth octet.
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uDataLength Read data length Word Specify the number of words to be read.
[Unsigned]/ ■When reading data from the RCPU, QCPU, or LCPU
Bit String • For channel 1 to channel 8: 1 to 960 words
[16-bit] • For channel 9 and channel 10: 1 to 8192 words
■When reading data from the QnACPU
• 1 to 480 words
(5) i_s32TargetDevice Target station read Character Specify the start address of the target station from which data is to be read.
device string (32)
(6) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(7) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(8) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(9) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(10) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
(11) o_uReadData Read data storage Word Specify the start number of the device for storing the read data 0
device [Unsigned]/
Bit String
[16-bit]
*1 Set the lower 2 bits (bit 0 and 1) of the set value to bit 8 and 9 of the control data (error completion type) of the READ instruction.
For the dedicated instruction, the error (D24AH) occurs if the lower 2 bits exceed the effective range.
FB details
Item Description
Available device Target module • RJ71GN11-T2
• RJ71GN11-SX
• RJ71GN11-EIP
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 82 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function reads device data from another station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
i_bEN
o_bENO
o_bOK
3
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
■RJ71GN11-T2
M+RJ71GN11_DeviceWrite
■RJ71GN11-SX
M+RJ71GN11_SX_DeviceWrite
■RJ71GN11-EIP
M+RJ71GN11_SE_DeviceWrite
Overview
Item Description
Overview Writes data by specifying a device in the programmable controller of another station.
Symbol
M+RJ71GN11_DeviceWrite
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_u2TargetAddress o_bErr: B (10)
(4) UW: i_uDataLength o_uErrId: UW (11)
(5) UW: i_uWriteData
(6) S: i_s32TargetDevice
(7) UW: i_uChannel
pbi_uCPU_Type (12)
pbi_bArrivalConfirm (13)
pbi_uResendCountMax (14)
pbi_uTimeUnit (15)
pbi_uMonitorTime (16)
pbi_bStationSpecific (17)
pbi_uTargetStation (18)
pbo_uResendCount (19)
pbo_u4ErrTime (20)
pbo_uErrStationAddress1 (21)
pbo_uErrStationAddress2 (22)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uDataLength Write data length Word Specify the number of words to be written.
[Unsigned]/ ■When writing data to the RCPU, QCPU, or LCPU
Bit String • For channel 1 to channel 8: 1 to 960 words
[16-bit] • For channel 9 and channel 10: 1 to 8192 words
■When writing data to the QnACPU
• 1 to 480 words
(5) i_uWriteData Write data storage Word Specify the start device of own station containing the write data.
device [Unsigned]/
Bit String
[16-bit]
(6) i_s32TargetDevice Target station write Character Specify the start device of the target station to which data is to be written.
device string (32)
(7) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(12) pbi_uCPU_Type Target station CPU Word 0000H, Specify the CPU type of the target station. 0
type [Unsigned]/ 03D0H to • 0000H: To CPU of target station (control CPU)
Bit String 03D3H, • 03D0H: To control system CPU
[16-bit] 03E0H to • 03D1H: To standby system CPU
03E3H, • 03D2H: To system A CPU
03FFH • 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(13) pbi_bArrivalConfirm Arrival Bit On or off Specify whether to use arrival acknowledgment. Off
acknowledgment ■Off: No check
• When the target station is within the own network,
sending data from the own station completes the
sending.
(1)
Es Ts
(1) Completion
Es: Execution source
Ts: Target station
• When the target station is within another network, data
arrival to the relay station within the own network
completes the sending.
(1)
Es Rs Ts
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
■On: Check
Sending data is completed when the data is written to the
target station.
(1)
Ts Es Rs Ts
(1)
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
(14) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String specified by "Arrival monitoring time".
[16-bit] • 0 to 15
(15) pbi_uTimeUnit Arrival monitoring Word 0, 1 Specify the unit of the "Arrival monitoring time".*1 0
time unit [Unsigned]/ • 0: 1s
Bit String • 1: 100ms
[16-bit]
*1 Set the lower 2 bits (bit 0 and 1) of the set value to bit 8 and 9 of the control data (execution/error completion type) of the WRITE
instruction.
For the dedicated instruction, the error (D24AH) occurs if the lower 2 bits exceed the effective range.
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_Send
■RJ71GN11-SX
M+RJ71GN11_SX_Send 3
■RJ71GN11-EIP
M+RJ71GN11_SE_Send
Overview
Item Description
Overview Sends data to the programmable controller of another station.
Symbol
M+RJ71GN11_Send
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_u2TargetAddress o_bErr: B (10)
(4) UW: i_uChannel o_uErrId: UW (11)
(5) UW: i_uTargetChannel
(6) UW: i_uDataLength
(7) UW: i_uSendData
pbi_bArrivalConfirm (12)
pbi_uResendCountMax (13)
pbi_uMonitorTime (14)
pbi_bStationSpecific (15)
pbi_uTargetStation (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrStationAddress1 (19)
pbo_uErrStationAddress2 (20)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uChannel Own station channel Word Specify the channel number to be used for data transmission by own
[Unsigned]/ station.
Bit String MELSEC iQ-R Programming Manual (Module Dedicated
[16-bit] Instructions)
(5) i_uTargetChannel Target station data Word 1 to 8 Specify the channel of the target station for storing data.
storage channel [Unsigned]/ When the target station is a CC-Link IE Field Network master/local
Bit String module, specify 1 or 2.
[16-bit]
(6) i_uDataLength Send data length Word Specify the number of words to be sent.
[Unsigned]/ • When the target station is RCPU, QCPU, or LCPU: 1 to 960 words
Bit String • When the target station is QnACPU: 1 to 480 words
[16-bit]
(7) i_uSendData Send data storage Word Specify the start device of own station containing the send data.
device [Unsigned]/
Bit String
[16-bit]
(1)
Es Ts
(1) Completion
Es: Execution source
Ts: Target station
• When the target station is within another network, data
arrival to the relay station within the own network
completes the sending.
(1)
Es Rs Ts
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
■On: Check
Sending data is completed when the data is written to the
target station.
(1)
Ts Es Rs Ts
(1)
(1) Completion
Es: Execution source
Rs: Relay station
Ts: Target station
(13) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String [16- specified by "Arrival monitoring time".
bit] • 0 to 15
(14) pbi_uMonitorTime Arrival monitoring Word 0, 1 to Specify the monitoring time until completion of processing. 0
time [Unsigned]/ 32767 If the processing is not completed within the monitoring
Bit String [16- time, data is resent until the value specified in "Maximum
bit] number of resends" is reached.
• 0: 10s
• Effective range 1 to 32767: 1s to 32767s
(15) pbi_bStationSpecific Target station Bit On or off Specify the specification method of a target station. Off
address specification • Off: Use the network number and station number.
method • On: Use the IP address (IPv4). (CC-Link IE TSN only).
■Public variables
No. Variable name Name Data type Description Default
value
(17) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit] If an error was detected, the number of resends performed
(result) between error detection and resend stop is stored.
(18) pbo_u4ErrTime Error occurrence Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
time String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(19) pbo_uErrStationAddr Error-detected Word [Unsigned]/Bit ■When "Target station address specification method" is off 0
ess1 station address 1 String [16-bit] The network number of the station in which an error was detected
is stored.
■When "Target station address specification method" is on
The IP addresses (the third and fourth octets) of the station in
which an error was detected are stored. (CC-Link IE TSN only)
Example: When the IP address is 192.168.1.2
0102h
(20) pbo_uErrStationAddr Error-detected Word [Unsigned]/Bit ■When "Target station address specification method" is off 0
ess2 station address 2 String [16-bit] The station number of the station in which an error was detected
is stored.
• Ethernet or CC-Link IE Controller Network
0001H to 0078H (1 to 120)
• CC-Link IE Field Network
007DH (125): Master station
0001H to 0078H (1 to 120): Local station, remote device station,
intelligent device station, submaster station
• CC-Link IE TSN
007DH: Master station
0001H to 0078H (1 to 120): Slave station
■When "Target station address specification method" is on
The IP addresses (the first and second octets) of the station in
which an error was detected are stored. (CC-Link IE TSN only)
Example: When the IP address is 192.168.1.2
C0A8h
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_Recv
■RJ71GN11-SX
M+RJ71GN11_SX_Recv 3
■RJ71GN11-EIP
M+RJ71GN11_SE_Recv
Overview
Item Description
Overview Reads the data received from the programmable controller of another station.
Symbol
M+RJ71GN11_Recv
(1) B: i_bEN o_bENO: B (4)
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uRecvChannel o_bErr: B (6)
o_uErrId: UW (7)
o_uRecvDataLength: UW (8)
o_uRecvData: UW (9)
pbi_bReadTiming (10)
pbi_uMonitorTime (11)
pbi_bStationSpecific (12)
pbo_uResendCount (13)
pbo_u4ErrTime (14)
pbo_uErrStationAddress1 (15)
pbo_uErrStationAddress2 (16)
pbo_uSendStationAddress1 (17)
pbo_uSendStationAddress2 (18)
pbo_uSendChannel (19)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: GN11_1, GN11_SE_1)
(3) i_uRecvChannel Receive data storage Word Specify the channel containing the data to be read.
channel [Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String [16- Instructions)
bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_bReadTiming Read timing Bit On Specify the timing of executing data read processing. On
• On: Start reading in the first END processing after the
module FB starts.
(11) pbi_uMonitorTime Arrival monitoring Word 0, 1 to Specify the monitoring time until completion of processing 0
time [Unsigned]/ 32767 (the setting is valid only when "Read timing" is on). When
Bit String the processing is not completed normally within the
[16-bit] monitoring time, the processing is completed with an error.
• 0: 10s
• Effective range 1 to 32767: 1s to 32767s
(12) pbi_bStationSpecific Sending station Bit On or off Specify the sending station address display method Off
address display • Off: Use the network number and station number.
method • On: Use the IP address (IPv4). (CC-Link IE TSN only).
■Public variables
No. Variable name Name Data type Description Default
value
(13) pbo_uResendCount Number of resends Word 0 is stored in this area. 0
[Unsigned]/
Bit String
[16-bit]
(14) pbo_u4ErrTime Error occurrence Word Clock data at the time of error occurrence is stored. 0
time [Unsigned]/ 1st word
Bit String • Upper 8 bits: Month (01H to 12H)
[16-bit] (0..3) • Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(15) pbo_uErrStationAddr Error-detected Word ■When "Sending station address display method" is off 0
ess1 station address 1 [Unsigned]/ The network number of the station in which an error was detected is
Bit String stored.
[16-bit] ■When "Sending station address display method" is on
The IP addresses (the third and fourth octets) of the station in which an
error was detected are stored. (CC-Link IE TSN only)
Example: When the IP address is 192.168.1.2
0102h
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_RemoteStopRun
■RJ71GN11-SX
M+RJ71GN11_SX_RemoteStopRun
■RJ71GN11-EIP
M+RJ71GN11_SE_RemoteStopRun
Overview
Item Description
Overview Sends a remote STOP/RUN request to the programmable controller of another station.
Symbol
M+RJ71GN11_RemoteStopRun
(1) B: i_bEN o_bENO: B (6)
(2) DUT: i_stModule o_bOK: B (7)
(3) UW: i_u2TargetAddress o_bErr: B (8)
(4) UW: i_uChannel o_uErrId: UW (9)
(5) UW: i_uRemoteType
pbi_uCPU_Type (10)
pbi_uResendCountMax (11)
pbi_uMonitorTime (12)
pbi_bStationSpecific (13)
pbi_uTargetStation (14)
pbi_uForciblyRun (15)
pbi_uDeviceClear (16)
pbo_uResendCount (17)
pbo_u4ErrTime (18)
pbo_uErrStationAddress1 (19)
pbo_uErrStationAddress2 (20)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated
Bit String [16- Instructions)
bit]
(5) i_uRemoteType Remote operation Word 1, 2 Specify remote RUN or STOP.
[Unsigned]/ • 1: Remote RUN
Bit String [16- • 2: Remote STOP
bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uCPU_Type Target station CPU Word 0000H, 03D0H Specify the CPU type of the target station. 0
type [Unsigned]/Bit to 03D3H, • 0000H: To CPU of target station (control CPU)
String [16-bit] 03E0H to • 03D0H: To control system CPU
03E3H, 03FFH • 03D1H: To standby system CPU
• 03D2H: To system A CPU
• 03D3H: To system B CPU
• 03E0H: To multiple CPU No.1
• 03E1H: To multiple CPU No.2
• 03E2H: To multiple CPU No.3
• 03E3H: To multiple CPU No.4
• 03FFH: To CPU of target station (control CPU)
(11) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if 5
ax resends [Unsigned]/Bit the data transfer is not completed within the
String [16-bit] monitoring time specified by "Arrival monitoring
time".
(12) pbi_uMonitorTime Arrival monitoring Word 0, 1 to 32767 Specify the monitoring time until completion of 0
time [Unsigned]/Bit processing. If the processing is not completed
String [16-bit] within the monitoring time, data is resent until the
value specified in "Maximum number of resends" is
reached.
• 0: 10s
• Effective range 1 to 32767: 1s to 32767s
(13) pbi_bStationSpecific Target station Bit On or off Specify the specification method of a target station. Off
address specification • Off: Use the network number and station number.
method • On: Use the IP address (IPv4). (CC-Link IE TSN
only).
(14) pbi_uTargetStation Target station Word 0 to 2 Specify the specification method of a target station. 0
specification method [Unsigned]/Bit • 0: Station number specification Station with the
String [16-bit] station number specified in "Target station
address"
• 1: Group specification All stations of the
transient transmission group number specified in
"Target station address" (For the CC-Link IE Field
Network, the value 1 cannot be specified.)
• 2: All stations All stations of the network
number specified in "Target station address"
(simultaneous broadcast except own station)
(15) pbi_uForciblyRun Specification of Word 1, 2 ■"Remote operation": 1 (remote RUN) 1
forced remote RUN [Unsigned]/Bit Specify whether to forcibly execute remote RUN.
String [16-bit] The forcible execution function enables forcible
execution of remote RUN from another station
when a station which executed remote STOP can
no longer execute remote RUN.
• 1: Not forcibly executed
• 2: Forcibly executed
■"Remote operation": 2 (remote STOP)
Any setting here is ignored and the following setting
is always used.
• 2: Forcibly executed
■Public variables 3
No. Variable name Name Data type Description Default
value
(17) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit] If an error was detected, the number of resends performed
(result) between error detection and resend stop is stored.
(18) pbo_u4ErrTime Error occurrence Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
time String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(19) pbo_uErrStationAddress Error-detected Word [Unsigned]/Bit ■When "Target station address specification method" is off 0
1 station address 1 String [16-bit] The network number of the station in which an error was
detected is stored.
■When "Target station address specification method" is on
The IP addresses (the third and fourth octets) of the station in
which an error was detected are stored. (Ethernet and CC-Link
IE TSN only)
Example: When the IP address is 192.168.1.2
0102h
(20) pbo_uErrStationAddress Error-detected Word [Unsigned]/Bit ■When "Target station address specification method" is off 0
2 station address 2 String [16-bit] The station number of the station in which an error was
detected is stored.
• Ethernet or CC-Link IE Controller Network
0001H to 0078H (1 to 120)
• CC-Link IE Field Network
007DH (125): Master station
0001H to 0078H (1 to 120): Local station, remote device
station, intelligent device station, submaster station
• CC-Link IE TSN
007DH: Master station
0001H to 0078H (1 to 120): Slave station
■When "Target station address specification method" is on
The IP addresses (the first and second octets) of the station in
which an error was detected are stored. (Ethernet and CC-Link
IE TSN only)
Example: When the IP address is 192.168.1.2
C0A8h
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_SLMP_DeviceRead_IP
■RJ71GN11-SX
M+RJ71GN11_SX_SLMP_DeviceRead_IP
■RJ71GN11-EIP
M+RJ71GN11_SE_SLMP_DeviceRead_IP
Overview
Item Description
Overview Reads data from the SLMP-compatible device by specifying IP address.
Symbol
M+RJ71GN11_SLMP_DeviceRead_IP
(1) B: i_bEN o_bENO: B (10)
(2) DUT: i_stModule o_bOK: B (11)
(3) UW: i_u2IP_Address o_bErr: B (12)
(4) UW: i_uSubCommand o_uErrId: UW (13)
(5) UW: i_uDeviceCode o_uReadData: UW (14)
(6) UW: i_u2DeviceNo
(7) UW: i_uDevicePoints
(8) UW: i_uChannel
(9) UW: i_uTarget_Port_No
pbi_uRequestModuleIO (15)
pbi_uResendCountMax (16)
pbi_uMonitorTime (17)
pbo_uResendCount (18)
pbo_u4ErrTime (19)
pbo_uErrIP_Address_3rd_4th (20)
pbo_uErrIP_Address_1st_2nd (21)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_1, GN11_SX_1, GN11_SE_1)
(3) i_u2IP_Address IP address of external Word [Unsigned]/Bit 00000001H to Specify the IP address of an external device. Specify
device String [16-bit] (0..1) DFFFFFFEH the third and fourth octets to the 1st word, and first
and second octets to the 2nd word. Specify a value
within the range of 1 to 254 (FEH) for the fourth octet.
b15 b8 b7 b0
+0 3: 1~255 4: 1~254
+1 1: 1~223 2: 1~255
1 to 4: IP address octet
(8) i_uChannel Own station channel Word [Unsigned]/Bit 1 to 17 Specify the channel to be used by the own station.*1
String [16-bit] MELSEC iQ-R Programming Manual (Module
Dedicated Instructions)
(9) i_uTarget_Port_No Destination port Word [Unsigned]/Bit 1 to 65534 Specify the UDP port number of an external device.
number String [16-bit] For the port number to specify, check the manual for
the external device.
*1 Set 1 when not adding a serial No. Set 2 to 9 when adding a serial No. Set 10 to 17 when communicating using the station number
extension frame.
0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0
M115 ... M100
b15 b8 b7 b0
1 2 3 4
D0
2nd word:
b15 b8 b7 b0
0 0 0 2
D1
3rd word:
b15 b8 b7 b0
1 D E F
D2
b15 b8 b7 b0
0 1 0 0
M102 M103 M100 M101
2nd word:
b15 b8 b7 b0
1 1 0 0
■Public variables
No. Variable name Name Data type Description Default
value
(18) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit] If an error was detected, the number of resends performed
(result) between error detection and resend stop is stored.
(19) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit Clock data at the time of error occurrence is stored.*1 0
String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(20) pbo_uErrIP_Address_ Error-detected device Word [Unsigned]/Bit The IP addresses (the third and fourth octets) of the device in 0
3rd_4th IP addresses (the third String [16-bit] which an error was detected are stored.*1
and fourth octets) Example: When the IP address is 192.168.1.2
0102h
(21) pbo_uErrIP_Address_ Error-detected device Word [Unsigned]/Bit The IP addresses (the first and second octets) of the device in 0
1st_2nd IP addresses (the first String [16-bit] which an error was detected are stored.*1
and second octets) Example: When the IP address is 192.168.1.2
C0A8h
*1 The value is stored only when the dedicated instruction was completed with an error.
The value set to the external device IP address of the input argument is stored in the error-detected device IP addresses (the third and
fourth octets) and the error-detected device IP addresses (the first and second octets).
o_bENO
o_bOK
3
o_bErr
o_uErrId 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
• For error completion (When the dedicated instruction was completed with an error)
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H (2)
pbo_uErrIP_Address_3rd_4th,
0H (3)
pbo_uErrIP_Address_1st_2nd
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
*1 If 0 (initial value) is stored in the error occurrence time, the error-detected device IP addresses (the third and fourth octets), and the
error-detected device IP addresses (the first and second octets), check and take actions using the manuals for the SLMP-compatible
device used.
Error codes
Error code Reference
0100H When the read unit is set to 0 (in units of words), a number other than 1 to 960 is specified.
When the read unit is set to 1 (in units of bits), a number other than 1 to 3972 is specified.
1000H to 3FFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
■RJ71GN11-T2
M+RJ71GN11_SLMP_DeviceWrite_IP
■RJ71GN11-SX
M+RJ71GN11_SX_SLMP_DeviceWrite_IP 3
■RJ71GN11-EIP
M+RJ71GN11_SE_SLMP_DeviceWrite_IP
Overview
Item Description
Overview Writes data to the SLMP-compatible device specified by an IP address.
Symbol
M+RJ71GN11_SLMP_DeviceWrite_IP
(1) B: i_bEN o_bENO: B (11)
(2) DUT: i_stModule o_bOK: B (12)
(3) UW: i_u2IP_Address o_bErr: B (13)
(4) UW: i_uSubCommand o_uErrId: UW (14)
(5) UW: i_uDeviceCode
pbi_uRequestModuleIO (15)
pbi_uResendCountMax (16)
pbi_uMonitorTime (17)
pbo_uResendCount (18)
pbo_u4ErrTime (19)
pbo_uErrIP_Address_3rd_4th (20)
pbo_uErrIP_Address_1st_2nd (21)
b15 b8 b7 b0
+0 3: 1~255 4: 1~254
+1 1: 1~223 2: 1~255
1 to 4: IP address octet
(4) i_uSubCommand Sub command Word [Unsigned]/Bit Specify the write unit and specification method of a
String [16-bit] device.
• 0th bit: Specify whether the device is written in units
of words or in units of bits.
0: In units of words
1: In units of bits
• 1st bit: Specify the combination of the number of
digits of the device code and start device number of
the device to be written.
0: Specify the device code in 2 digits and the start
device number in 6 digits (for MELSEC-Q/L series).
1: Specify the device code in 4 digits and the start
device number in 8 digits (for MELSEC iQ-R series).
(5) i_uDeviceCode Device code Word [Unsigned]/Bit Specify the device code of the device to be written in
String [16-bit] binary code.
• When the 1st bit of the subcommand is 0: 2 digits
• When the 1st bit of the subcommand is 1: 4 digits
(6) i_u2DeviceNo Head device No. Word [Unsigned]/Bit Specify the start device number of the device to be
String [16-bit] (0..1) written in binary code.
• When the 1st bit of the subcommand is 0: 6 digits
• When the 1st bit of the subcommand is 1: 8 digits
(7) i_uDevicePoints Number of device Word [Unsigned]/Bit Specify the number of device points of the device to be
points String [16-bit] written in binary code.
• When the 0th bit of the subcommand is 0
1 to 960
• When the 0th bit of the subcommand is 1
Own station channel is 1 to 9: 1 to 3972
Own station channel is 10 to 17: 1 to 3960
3
0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0
M115 ... M100
Example: When writing the word device D0 to D2 in
units of words
1st word:
b15 b8 b7 b0
1 2 3 4
D0
2nd word:
b15 b8 b7 b0
0 0 0 2
D1
3rd word:
b15 b8 b7 b0
1 D E F
D2
b15 b8 b7 b0
0 1 0 0
M102 M103 M100 M101
2nd word:
b15 b8 b7 b0
1 1 0 0
(9) i_uChannel Own station channel Word [Unsigned]/Bit 1 to 17 Specify the channel to be used by the own station.*1
String [16-bit] MELSEC iQ-R Programming Manual (Module
Dedicated Instructions)
(10) i_uTarget_Port_No Destination port Word [Unsigned]/Bit 1 to 65534 Specify the UDP port number of an external device.
number String [16-bit] For the port number to specify, check the manual for
the external device.
*1 Set 1 when not adding a serial No. Set 2 to 9 when adding a serial No. Set 10 to 17 when communicating using the station number
extension frame.
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(15) pbi_uRequestModuleIO Requested module I/ Word 03E0H to 03E3H, 03FFH Specify the module of the access 03FFH
O No. [Unsigned]/ destination.
Bit String [16- • 03E0H: Multiple CPU No.1
bit] • 03E1H: Multiple CPU No.2
• 03E2H: Multiple CPU No.3
• 03E3H: Multiple CPU No.4
• 03FFH: Own station, control
CPU
(16) pbi_uResendCountMax Maximum number of Word 0 to 15 Specify the number of resends to 5
resends [Unsigned]/ be performed if the data transfer is
Bit String [16- not completed within the
bit] monitoring time specified by
"Arrival monitoring time".
• 0 to 15
(17) pbi_uMonitorTime Arrival monitoring Word 0, 1 to 32767 Specify the monitoring time until 0
time [Unsigned]/ completion of processing. If the
Bit String [16- processing is not completed within
bit] the monitoring time, data is resent
until the value specified in
"Maximum number of resends" is
reached.
• 0: 10s
• Effective range 1 to 32767: 1s to
32767s
*1 The value is stored only when the dedicated instruction was completed with an error.
The value set to the external device IP address of the input argument is stored in the error-detected device IP addresses (the third and
fourth octets) and the error-detected device IP addresses (the first and second octets).
FB details
Item Description
Available device Target module • RJ71GN11-T2
• RJ71GN11-SX
• RJ71GN11-EIP
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 268 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing • When i_bEN (execution command) is turned on, this function writes device data of the SLMP-compatible device.
• This FB is executed specifying the IP address of an external device.
• This FB uses Device Write (command: 1401) of the SLMP for the Write command. The message of the SLMP command is a binary
code. ( SLMP Reference Manual)
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
o_bENO
o_bOK
o_bErr
o_uErrId 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
• For error completion (When the dedicated instruction was completed with an error)
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H (2)
pbo_uErrIP_Address_3rd_4th,
0H (3)
pbo_uErrIP_Address_1st_2nd
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
*1 If 0 (initial value) is stored in the error occurrence time, the error-detected device IP addresses (the third and fourth octets), and the
error-detected device IP addresses (the first and second octets), check and take actions using the manuals for the SLMP-compatible
device used.
Error codes
Error code Reference
0100H When the read unit is set to 0 (in units of words), a number other than 1 to 960 is specified.
When the read unit is set to 1 (in units of bits) and the own station channel is 1 to 9: A number other than 1 to 3972 is specified.
When the read unit is set to 1 (in units of bits) and the own station channel is 10 to 17: A number other than 1 to 3960 is specified.
1000H to 3FFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
■RJ71GN11-T2
M+RJ71GN11_SetAddress
■RJ71GN11-SX
M+RJ71GN11_SX_SetAddress
Overview
Item Description
Overview Sets the station number/IP address for the own station.
Symbol
M+RJ71GN11_SetAddress
(1) B: i_bEN o_bENO: B (5)
(2) DUT: i_stModule o_bOK: B (6)
(3) UW: i_uStationNo o_bErr: B (7)
(4) UW: i_u2IPAddress o_uErrId: UW (8)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: GN11_1, GN11_SX_1)
(3) i_uStationNo Station number of Word 0 to 120 Specify the station number to be set.
the own station [Unsigned]/ Master station: 0
Bit String Local station: 1 to 120
[16-bit]
(4) i_u2IPAddress IP address Word 00000001H Specify the IP address to be set. When specifying the numbers using a label,
[Unsigned]/ to use an array as the data type.
Bit String DFFFFFFEH
b15 b8 b7 b0
[16-bit]
(0..1) +0 3 4
+1 1 2
1 to 4: IP address octet
FB details
Item Description
Available device Target module • RJ71GN11-T2
• RJ71GN11-SX
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 50 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing Set the station number/IP address when i_bEN (execution instruction) is turned on.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
Timing chart of I/O • For normal completion
signals
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
D000H to DFFFH
Name
M+RJ71GN11_SetParameterX
Overview
Item Description 3
Overview Sets parameters for a module.
Symbol
M+RJ71GN11_SetParameterX
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_uTotalStations o_bErr: B (10)
(4) UW: i_u2175NetworkConfigurationSet o_uErrId: UW (11)
(5) UW: i_u16ReservedStationSet
(6) UW: i_u16ErrInvalidStationSet
(7) UW: i_u11CommunicationCycleSet
pbi_uTopologySet (12)
pbi_bNetworkConfigurationSetFlg (13)
pbi_bReservedStationSetFlg (14)
pbi_bErrInvalidStationSetFlg (15)
pbi_bDatalinkFaultyStationSet (16)
pbi_bCPU_StopOutputSet (17)
pbi_bCPU_StopErrOutputSet (18)
pbi_bClassSet (19)
pbi_uDisconnectionDetectionSet (20)
pbi_uCommModeSet (21)
pbi_bCommSpeedSet (22)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the instance of the module label as an argument.
(Example: GN11_1)
(3) i_uTotalStations Total number of Word 2 to 121 Specify the total number of stations of network module connected.
stations [Unsigned]/
Bit String
[16-bit]
(4) i_u2175NetworkCo Network Word Specify the start address of the storage location of network configuration setting
nfigurationSet configuration [Unsigned]/ data.
setting data Bit String Set data for the number of stations specified in "Total number of stations".
[16-bit] (Page 127 Network configuration setting data)
(0..2174)
b15 b8 b7 b0
1 2
Only for the slave station, set the IP address. For the master station, the IP address
setting is not required.
32 Communication cycle 0 to 2 0: Standard cycle
setting 1: Medium speed
2: Low speed
33 to 2174 For 3rd to 121st module (slave station)
For setting details, refer to the 2nd module (15 to 32).
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_RemoteRead
■RJ71GN11-EIP
M+RJ71GN11_SE_RemoteRead
Overview
Item Description
Overview Reads data from the buffer memory area of the remote station in units of words.
Symbol
M+RJ71GN11_RemoteRead
(1) B: i_bEN o_bENO: B (7)
(2) DUT: i_stModule o_bOK: B (8)
(3) UW: i_u2TargetAddress o_bErr: B (9)
(4) UD: i_udTargetBuffer o_uErrId: UW (10)
(5) UW: i_uDataLength o_uReadData: UW (11)
(6) UW: i_uChannel
pbi_uTargetStartIO (12)
pbi_uResendCountMax (13)
pbi_uMonitorTime (14)
pbi_bStationSpecific (15)
pbo_uResendCount (16)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_udTargetBuffer Read buffer Double 00000000H Specify the start buffer memory address of the target station containing the read
memory of the word to data.
target station [Unsigned]/ FFFFFFFFH
Bit String
[32-bit]
(5) i_uDataLength Read data Word 1 to 240 Specify the number of read data points (in units of words).
length [Unsigned]/
Bit String
[16-bit]
(6) i_uChannel Own station Word 1 to 32 Specify the channel to be used by the own station.
channel [Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(7) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(8) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(9) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(10) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
(11) o_uReadData Read data storage Word Specify the start number of the device for storing the read data 0
device [Unsigned]/
Bit String
[16-bit]
■Public variables
No. Variable name Name Data type Description Default
value
(16) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit] If an error was detected, the number of resends performed (result)
between error detection and resend stop is stored.
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_RemoteWrite
■RJ71GN11-EIP
M+RJ71GN11_SE_RemoteWrite 3
Overview
Item Description
Overview Writes data to the buffer memory area of the remote station in units of words.
Symbol
M+RJ71GN11_RemoteWrite
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_u2TargetAddress o_bErr: B (10)
(4) UD: i_udTargetBuffer o_uErrId: UW (11)
(5) UW: i_uWriteData
(6) UW: i_uDataLength
(7) UW: i_uChannel
pbi_uTargetStartIO (12)
pbi_uResendCountMax (13)
pbi_uMonitorTime (14)
pbi_bStationSpecific (15)
pbo_uResendCount (16)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_udTargetBuffer Target station Double 00000000 Specify the start buffer memory address of the target station to which the data is
write buffer word H to written.
[Unsigned]/ FFFFFFFF
Bit String H
[32-bit]
(5) i_uWriteData Write data storage Word Specify the start device of own station containing the write data.
device [Unsigned]/
Bit String
[16-bit]
(6) i_uDataLength Write data length Word 1 to 240 Specify the number of write data points (in units of words).
[Unsigned]/
Bit String
[16-bit]
(7) i_uChannel Own station Word 1 to 32 Specify the channel to be used by the own station.
channel [Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Output arguments
No. Variable name Name Data type Description Default
value
(8) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(9) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(10) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(11) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
■Public variables
No. Variable name Name Data type Description Default
value
(16) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit] If an error was detected, the number of resends performed (result)
between error detection and resend stop is stored.
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Name
■RJ71GN11-T2
M+RJ71GN11_RemoteReset_IP
■RJ71GN11-SX
M+RJ71GN11_SX_RemoteReset_IP
■RJ71GN11-EIP
M+RJ71GN11_SE_RemoteReset_IP
Overview
Item Description
Overview Sends the remote STOP of an SLMP request to the target station specified by an IP address and then sends the remote RESET.
Symbol
M+RJ71GN11_RemoteReset_IP
(1) B: i_bEN o_bENO: B (6)
(2) DUT: i_stModule o_bOK: B (7)
(3) UW: i_u2TargetAddress o_bErr: B (8)
(4) UW: i_uTarget_Port_No o_uErrId: UW (9)
(5) UW: i_uChannel
pbo_u4ErrTime (10)
pbo_uErrIP_Address_3rd_4th (11)
pbo_uErrIP_Address_1st_2nd (12)
1 to 4: IP address octet
(4) i_uTarget_Port_No Destination port Word 1 to 65534 Specify the UDP port number of an external device.
number [Unsigned]/ For the port number to specify, check the manual for the external device.
Bit String
[16-bit]
(5) i_uChannel Own station Word 1 to 17 Specify the channel to be used by the own station.*1
channel [Unsigned]/
Bit String
[16-bit]
*1 To perform communications using the frame without the serial number on this FB, specify 1 to the own station channel. When a number
of 2 to 9 is specified, this FB communicates using the frame with the serial number. When a number of 10 to 17 is specified, this FB
communicates using the station number extension frame.
■Output arguments
No. Variable name Name Data type Description Default
value
(6) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(7) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(8) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(9) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
*1 The value is stored only when the dedicated instruction was completed with an error.
The value set to the target station address of the input argument is stored in the error-detected device IP addresses (the third and fourth
octets) and the error-detected device IP addresses (the first and second octets).
FB details
Item Description
Available device Target module • RJ71GN11-T2
• RJ71GN11-SX
• RJ71GN11-EIP
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 362 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function sends the remote STOP of an SLMP request to the target station and then
sends the remote RESET.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
o_bENO
o_bOK
3
o_bErr
o_uErrId 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
• For error completion (When the dedicated instruction was completed with an error)
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H (2)
pbo_uErrIP_Address_3rd_4th,
0H (3)
pbo_uErrIP_Address_1st_2nd
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
*1 If 0 (initial value) is stored in the error occurrence time, the error-detected device IP addresses (the third and fourth octets), and the
error-detected device IP addresses (the first and second octets), check and take actions using the manuals for the SLMP-compatible
device used.
Error codes
Error code Reference
1000H to 3FFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
4000H to 4FFFH MELSEC iQ-R CPU Module User's Manual (Application)
D000H to DFFFH MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
■RJ71GN11-T2
M+RJ71GN11_RemoteReset2_IP
■RJ71GN11-SX
M+RJ71GN11_SX_RemoteReset2_IP 3
■RJ71GN11-EIP
M+RJ71GN11_SE_RemoteReset2_IP
Overview
Item Description
Overview Sends the remote RESET of an SLMP request to the target station specified by an IP address.
Symbol
M+RJ71GN11_RemoteReset2_IP
(1) B: i_bEN o_bENO: B (6)
(2) DUT: i_stModule o_bOK: B (7)
(3) UW: i_u2TargetAddress o_bErr: B (8)
(4) UW: i_uTarget_Port_No o_uErrId: UW (9)
(5) UW: i_uChannel
pbo_u4ErrTime (10)
pbo_uErrIP_Address_3rd_4th (11)
pbo_uErrIP_Address_1st_2nd (12)
Labels
■Input arguments
No. Variable name Name Data Range Description
type
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: GN11_1, GN11_SX_1, GN11_SE_1)
(3) i_u2TargetAddress IP address of Word Right Specify the IP address of an external device. When specifying the address using
external device [Unsigned] a label, use an array as the data type.
/Bit String • 00000001H to DFFFFFFEH
[16-bit] Specify a value within the range of 1 to 254 (FEH) for the fourth octet.
(0..1)
b15 b8 b7 b0
+0 3 4
+1 1 2
1 to 4: IP address octet
(4) i_uTarget_Port_No Destination port Word 1 to 65534 Specify the UDP port number of an external device.
number [Unsigned] For the port number to specify, check the manual for the external device.
/Bit String
[16-bit]
(5) i_uChannel Own station Word 1 to 17 Specify the channel to be used by the own station.*1
channel [Unsigned]
/Bit String
[16-bit]
*1 To perform communications using the frame without the serial number on this FB, specify 1 to the own station channel. When a number
of 2 to 9 is specified, this FB communicates using the frame with the serial number. When a number of 10 to 17 is specified, this FB
communicates using the station number extension frame.
■Public variables
No. Variable name Name Data type Description Default
value
(10) pbo_u4ErrTime Error occurrence Word [Unsigned]/Bit Clock data at the time of error occurrence is stored.*1 0
time String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(11) pbo_uErrIP_Address Error-detected Word [Unsigned]/Bit The IP addresses (the third and fourth octets) of the station in 0
_3rd_4th device IP addresses String [16-bit] which an error was detected are stored.*1
(the third and fourth Example: When the IP address is 192.168.1.2
octets) 0102h
(12) pbo_uErrIP_Address Error-detected Word [Unsigned]/Bit The IP addresses (the first and second octets) of the station in 0
_1st_2nd device IP addresses String [16-bit] which an error was detected are stored.*1
(the first and second Example: When the IP address is 192.168.1.2
octets) C0A8h
*1 The value is stored only when the dedicated instruction was completed with an error.
The value set to the target station address of the input argument is stored in the error-detected device IP addresses (the third and fourth
octets) and the error-detected device IP addresses (the first and second octets).
FB details
Item Description
Available device Target module • RJ71GN11-T2
• RJ71GN11-SX
• RJ71GN11-EIP
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 171 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function sends the remote RESET of an SLMP request to the target station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
o_bENO
o_bOK
3
o_bErr
o_uErrId 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
• For error completion (When the dedicated instruction was completed with an error)
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H (2)
pbo_uErrIP_Address_3rd_4th,
0H (3)
pbo_uErrIP_Address_1st_2nd
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
pbo_u4ErrTime 0H
pbo_uErrIP_Address_3rd_4th,
0H
pbo_uErrIP_Address_1st_2nd
*1 If 0 (initial value) is stored in the error occurrence time, the error-detected device IP addresses (the third and fourth octets), and the
error-detected device IP addresses (the first and second octets), check and take actions using the manuals for the SLMP-compatible
device used.
Error codes
Error code Reference
1000H to MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
3FFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
4000H to MELSEC iQ-R CPU Module User's Manual (Application)
4FFFH
D000H to MELSEC iQ-R CC-Link IE TSN User's Manual (Application)
DFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
M+RJ71GN11_SE_ConnectionOpen
Overview
Item Description
Overview Opens (establishes) a connection for data communication with an external device.
Symbol
M+RJ71GN11_SE_ConnectionOpen
(1) B:i_bEN o_bENO:B (4)
(2) DUT:i_stModule o_bOK:B (5)
(3) UW:i_uConnectionNo o_bErr:B (6)
o_uErrId:UW (7)
pbi_bUseParameters (8)
pbi_uProtocol (9)
pbi_uOpen_System (10)
pbi_uLocal_Port_No (11)
pbi_uTarget_Port_No (12)
pbi_u2IP_Address (13)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_SE_1)
(3) i_uConnectionNo Connection No. Word 1 to 16 Specify the number of the connection to be
[Unsigned]/ opened.
Bit String • 1 to 8: Port 1, socket communications
[16-bit] • 9 to 16: Port 2, socket communications
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
b15 b8 b7 b0
+0 (3) (4)
+1 (1) (2)
FB details
Item Description
Available device Target module RJ71GN11-EIP
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 102 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to the GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function opens (establishes) a connection for data communication with an external
device.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
M+RJ71GN11_SE_ConnectionClose
Overview
Item Description
Overview Closes (disconnects) a connection for data communication with an external device.
Symbol
M+RJ71GN11_SE_ConnectionClose
(1) B:i_bEN o_bENO:B (4) 4
(2) DUT:i_stModule o_bOK:B (5)
(3) UW:i_uConnectionNo o_bErr:B (6)
o_uErrId:UW (7)
pbo_uErrConn_No (8)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_SE_1)
(3) i_uConnectionNo Connection No. Word 1 to 16 Specify the number of the connection to be
[Unsigned]/ closed.
Bit String • 1 to 8: Port 1, socket communications
[16-bit] • 9 to 16: Port 2, socket communications
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
■Public variables
No. Variable name Name Data type Description Default
value
(8) pbo_uErrConn_No Error connection Word [Unsigned]/ The number of the connection for which close processing was 0
No. Bit String [16-bit] completed with an error is stored.
If 65535 (FFFFH) is specified in i_uConnectionNo (connection No.), the
number of the connection for which close processing was first
completed with an error is stored.
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
M+RJ71GN11_SE_Recv_Socket
Overview
Item Description
Overview Reads the data received through socket communications.
Symbol
M+RJ71GN11_SE_Recv_Socket
(1) B:i_bEN o_bENO:B (4) 4
(2) DUT:i_stModule o_bOK:B (5)
(3) UW:i_uConnectionNo o_bErr:B (6)
o_uErrId:UW (7)
o_uRecvData:UW (8)
pbo_uReadTiming (9)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_SE_1)
(3) i_uConnectionNo Connection No. Word 1 to 16 Specify the number of the connection to which
[Unsigned]/ received data is to be read out.
Bit String • 1 to 8: Port 1, socket communications
[16-bit] • 9 to 16: Port 2, socket communications
■Output arguments
No. Variable name Name Data type Description Default
value
(4) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(5) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(6) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(7) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
■Operation parameters
No. Variable name Name Data Range Description Default
type value
(9) pbi_bReadTiming Read timing Bit On or off Specify the timing of executing data read processing. On
• Off: Start reading soon after the FB starts.
• On: Start reading in the first END processing after the FB
starts.
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
M+RJ71GN11_SE_Send_Socket
Overview
Item Description
Overview Sends the data to the external device of the specified connection.
Symbol
M+RJ71GN11_SE_Send_Socket
(1) B:i_bEN o_bENO:B (5)
(2) DUT:i_stModule o_bOK:B (6)
(3) UW:i_uConnectionNo o_bErr:B (7)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_SE_1)
(3) i_uConnectionNo Connection No. Word 1 to 16 Specify the number of the connection of an
[Unsigned]/ external device to which the data is to be sent.
Bit String • 1 to 8: Port 1, socket communications
[16-bit] • 9 to 16: Port 2, socket communications
(4) i_uSendData Send data storage Word Specify the start number of the device containing
destination [Unsigned]/ the send data length and data to be sent.
Bit String • 1st word: Send data length (unit: byte)
[16-bit] • 2nd word (upper 8 bits): Send data 1
• 2nd word (lower 8 bits): Send data 2
• 3rd word (upper 8 bits): Send data 3
• 3rd word (lower 8 bits): Send data 4
• n(th) word (upper 8 bits): Send data (n-1)2-1
• n(th) word (lower 8 bits): Send data (n-1)2
The range of send data length varies depending
on the connection No.
• Connection No.1 to No.8: 1 to 2046
Connection No.9 to No.16: 1 to 10238
■Output arguments
No. Variable name Name Data type Description Default
value
(5) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(6) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(7) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(8) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/Bit
String [16-bit]
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
C000H to CFFFH MELSEC iQ-R CC-Link IE TSN Plus Master/Local Module User's Manual
Name
M+RJ71GN11_SE_Refresh_Data
Overview
Item Description
Overview Transfers the data from the buffer memory in the target module to the module label.
Symbol
M+RJ71GN11_SE_Refresh_Data
(1) B:i_bEN o_bENO:B (3)
(2) DUT:i_stModule
Labels
■Input arguments
No. Variable name Name Data Range Description
type
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structure Specify the module for which the FB is to be
executed.
Specify the module label of the modules.
(Example: GN11_SE_1)
■Output arguments
No. Variable name Name Data type Description Default
value
(3) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
o_bENO
Precautions When another FB is used, write the program so that this FB is executed every scan, at the beginning of the program.
Error codes
This FB has no error code.
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_C_StationNoSet RJ71EN71(CCIEC) _RJ71EN71(CCIEC)
M+RJ71EN71_EC_StationNoSet RJ71EN71(E+CCIEC) _RJ71EN71(E+IEC)
M+RJ71EN71_F_StationNoSet RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_StationNoSet RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GP21(S)-SX
M+RJ71GP21_StationNoSet 5
■RJ71GF11-T2
M+RJ71GF11_StationNoSet
Overview
Item Description
Overview Sets the station number of the own station.
Symbol
M+RJ71GP21_StationNoSet
(1) B: i_bEN o_bENO: B (4)
(2) DUT: i_stModule o_bOK: B (5)
(3) UW: i_uSetStationNo o_bErr: B (6)
o_uErrId: UW (7)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(Example: EN71_EE_1, EN71_EF_1, EN71_F_1, GF11_1, GP21_1)
(3) i_uSetStationNo Setting station Word 1 to 120 Specifies the station number to be set.
number [Unsigned]/
Bit String
[16-bit]
FB details
Item Description
Available device Target module • RJ71EN71
• RJ71GP21(S)-SX
• RJ71GF11-T2
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 44 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function sets the station number of the own station.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
E000H to EFFFH MELSEC iQ-R CC-Link IE Controller Network User's Manual (Application)
Name
■RJ71GP21(S)-SX
M+RJ71GP21_RedundantSystem_GetAddress
■RJ71GF11-T2
M+RJ71GF11_RedundantSystem_GetAddress
■RJ71LP21-25
M+RJ71LP21_RedundantSystem_GetAddress
Overview
Item Description
Overview Identifies the control system or standby system in the target (another station) redundant system and acquires the address of the control
system or standby system in the redundant system.
Symbol
M+RJ71GP21_RedundantSystem_GetAddress
(1) B: i_bEN o_bENO: B (5)
(2) DUT: i_stModule o_bOK: B (6)
(3) UW: i_u2SystemA_TargetAddress o_bErr: B (7)
(4) UW: i_u2SystemB_TargetAddress o_uErrId: UW (8)
o_u2TargetAddress: UW (9)
pbi_uTargetSystem_Type (10)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_u2SystemA_Target System A target Word Specify the network number and station number of the system A target
Address station address [Unsigned]/ station.
Bit String • 1st word: Network number (1 to 239)
[16-bit] • 2nd word: Station number
(0..1) Network number
• Set the network number same as that of the FB executing station.
Station number of CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, submaster station
Station number of MELSECNET/H
• 1 to 64
(4) i_u2SystemB_Target System B target Word Specify the network number and station number of the system B target
Address station address [Unsigned]/ station.
Bit String • 1st word: Network number (1 to 239)
[16-bit] • 2nd word: Station number
(0..1) Network number
• Set the network number same as that of the FB executing station.
Station number of CC-Link IE Controller Network
• 1 to 120
Station number of CC-Link IE Field Network
• 125: Master station
• 1 to 120: Local station, submaster station
Station number of MELSECNET/H
• 1 to 64
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uTargetSystem_T Target system type Word 0 to 1 Specify the type of the target system. 0
ype [Unsigned]/ • 0: Control system
Bit String • 1: Standby system
[16-bit]
FB details
Item Description
Available device Target module • RJ71GF11-T2*1
• RJ71GP21(S)-SX
• RJ71LP21-25
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic • RJ71GF11-T2: 425 steps
steps • RJ71GP21(S)-SX: 237 steps
• RJ71LP21-25: 237 steps
The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function identifies the control system or standby system in the target (another
station) redundant system and acquires the address of the control system or standby system in the redundant system.
This FB is used in combination with the following FBs.
• DeviceRead
• DeviceWrite
• Send
• RemoteStopRun
• ReadTime
• WriteTime
The procedure when this FB is used with DeviceRead is shown below. To execute DeviceRead to the control system in the redundant
system, execute DeviceRead to the target station address of the control system which is acquired by this FB.
Specify the system A and system B target station addresses and execute this FB. (Specify the control system.)
The target station address of the control system is output.
Set the target station address of the control system to i_u2TargetAddress of DeviceRead and execute DeviceRead.
DeviceRead is executed to the control system.
FB compilation Macro type
method
FB operation ON-time execution type
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
o_u2TargetAddress 0H (1) 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
o_u2TargetAddress 0H
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_F_SetParameter RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_SetParameter RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GF11-T2
M+RJ71GF11_SetParameter
Overview
Item Description
Overview Sets the parameters in the master, submaster, and local stations.
Symbol
6
M_RJ71GF11_SetParameter
(1) B: i_bEN o_bENO: B (7)
(2) DUT: i_stModule o_bOK: B (8)
(3) UW: i_uTotalStations o_bErr: B (9)
(4) UW: i_u605NetworkConfigurationSet o_uErrId: UW (10)
(5) UW: i_u8ReservedStationSet
(6) UW: i_u8ErrInvalidStationSet
pbi_uConstantLinkScanTime (11)
pbi_uIpAddress (12)
pbi_bNetworkConfigurationSetFlg (13)
pbi_bReservedStationSetFlg (14)
pbi_bErrInvalidStationSetFlg (15)
pbi_bSubMasterSet (16)
pbi_bIP_PacketTransferFlg (17)
pbi_bDatalinkFaultyStationSet (18)
pbi_bCPU_StopOutputSet (19)
pbi_bCPU_StopErrOutputSet (20)
pbi_bLinkScanModeSet (21)
pbi_bTopologySet (22)
pbi_bMasterReturnSet (23)
pbi_bSubMasterOperateParam (24)
(4) (5)
If the specified total number of slave stations does not match the individual station setting data, the total number of individual
stations specified in the total number of slave stations take precedence and any individual station information exceeding the
total number of slave stations is ignored. Note that 1 is added to the total number of slave stations when "Presence of
submaster function" is on (enabled).
Example) When the station information of 10 stations is set even if the total number of slave stations is 2.
The 1st and 2nd information is enabled and parameters which are set the 3rd to 10th station information are ignored.
■Output arguments
No. Variable name Name Data Description Default
type value
(7) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(8) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(9) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(10) o_uErrId Error code Word An error code is stored at error completion. 0
[unsigned]
*1 Valid only when "Submaster station parameter operation setting" is ON (Operating with the parameters of the own (submaster) station)
FB details
Item Description
Available device Target module • RJ71EN71
• RJ71GF11-T2
6
• RnENCPU (network part)
CPU module RCPU
Engineering tool GX Works3
Language Ladder diagram
Number of basic 79 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution command) is turned on, this function sets parameters for a module.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
Name
M+RJ71GF11_SetParameterRedundant
Overview
Item Description
Overview Sets the parameters in the master station in the redundant system.
Symbol
M+RJ71GF11_SetParameterRedundant
(1) B: i_bEN o_bENO: B (8)
(2) DUT: i_stModule o_bOK: B (9)
(3) UW: i_uTotalStations o_bErr: B (10)
(4) UW: i_u605NetworkConfigurationSet o_uErrId: UW (11)
(5) UW: i_u8ReservedStationSet
(6) UW: i_u8ErrInvalidStationSet
(7) UW: i_u16RedundantSystemSet 6
pbi_uConstantLinkScanTime (12)
pbi_uIpAddress (13)
pbi_uMonitoringTime (14)
pbi_bNetworkConfigurationSetFlg (15)
pbi_bReservedStationSetFlg (16)
pbi_bErrInvalidStationSetFlg (17)
pbi_bRedundantSystemFlg (18)
pbi_bSubMaseterSet (19)
pbi_bIP_PacketTransferFlg (20)
pbi_bMonitoringTimeFlg (21)
pbi_bDatalinkFautlyStationSet (22)
pbi_bCPU_StopOutputSet (23)
pbi_bCPU_StopErrOutputSet (24)
pbi_bLinkScanModeSet (25)
pbi_bTopologySet (26)
pbi_bMasterReturnSet (27)
pbi_bSubMasterOperateParam (28)
Labels
■Input arguments
No. Variable Name Data type Range Description
name
(1) i_bEN Execution Bit On: Start FB.
command Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_uTotalStations Total number of Word [Unsigned]/ 1 to 120, 121 Specify the total number of the slave stations connected.
slave stations Bit String [16-bit] 1 to 120: Applicable when "Presence of submaster function" is off
(disabled)
1 to 121: Applicable when "Presence of submaster function" is on
(enabled)
(4) i_u605NetworkC Network Word [Unsigned]/ Specify the start address of the storage location of network configuration
onfigurationSet configuration Bit String [16-bit] setting data.
setting data (0..604) When specifying the address using a label, use an array as the data type.
Set data for the number of stations specified in "Total number of slave
stations". ( Page 203 Network configuration setting data)
(4) (5)
If the specified total number of slave stations does not match the individual station setting data, the total number of individual
stations specified in the total number of slave stations take precedence and any individual station information exceeding the
total number of slave stations is ignored. Note that 1 is added to the total number of slave stations when "Presence of
submaster function" is on (enabled).
Ex.
When the station information of 10 stations is set even if the total number of slave stations is 2
The 1st and 2nd information is enabled and parameters which are set to the 3rd to 10th station information are ignored.
■Operation parameters
: Can be set, : Cannot be set (for master station, submaster station, local station, redundant slave station)
No. Variable Name Data type Range Description Default Redundant Redundant line
name value master station
System System System System
A B A B
(12) pbi_uConstant Constant link Word 0, 1 to Specify the constant link scan 0
LinkScanTime scan time [Unsigned]/ 200 time.
Bit String • 0: Not set (default value)
[16-bit] • 1 to 200: 1ms to 200ms
(13) pbi_uIpAddress Upper 2 Word Set the IP address when the IP 0
digits of IP [Unsigned]/ packet transfer function is used.
address Bit String Only the upper two digits (1st
[16-bit] and 2nd octets) of a 4-digit IP
address can be set. The 3rd and
4th digits are each determined
automatically from the network
number and station number
(master station is 125).
(14) pbi_uMonitorin System Word 5 to Set the system switching 2000
gTime switching [Unsigned]/ 5000 monitoring time.
monitoring Bit String This parameter is enabled when
time [16-bit] the system switching monitoring
time setting is on (Enable).
(15) pbi_bNetworkC Presence of Bit Off, on Specify whether to enable/ Off
onfigurationSet network disable the network
Flg configuration configuration setting data.
setting data • Off: Disable
• On: Enable
(16) pbi_bReserved Presence of Bit Off, on Specify whether to enable/ Off
StationSetFlg reserved disable the reserved station
station specification data.
specification • Off: Disable
data • On: Enable
(17) pbi_bErrInvalid Presence of Bit Off, on Specify whether to enable/ Off
StationSetFlg error invalid disable the error invalid station
station setting data.
setting data • Off: Disable
• On: Enable
(18) Pbi_bRedunda Presence of Bit Off, on Specify whether to enable/ Off
ntSystemFlg redundant disable the redundant system
system setting data.
setting data • Off: Disable
• On: Enable
(19) pbi_bSubMaset Presence of Bit Off, on Specify whether to use the Off *1 *1 *1
erSet submaster submaster function
function • Off: Do not use.
• On: Use.
(20) pbi_bIP_Packe Presence of Bit Off, on Specify whether to enable/ Off
tTransferFlg IP packet disable the IP packet transfer
transfer function.
function • Off: Disable
• On: Enable
*1 For the redundant master station, the parameter is fixed to on (use). For the redundant line, the parameter is fixed to off (not use).
*2 For the redundant master station, the parameter is fixed to on (returning as the submaster operating station). For the redundant line, the
parameter is fixed to off (returning as the master operating station).
*3 These parameters are fixed to on (operating with the parameters of the own (submaster) station).
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_F_ReadSystemTypeInformation RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_ReadSystemTypeInformation RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GF11-T2
M+RJ71GF11_ReadSystemTypeInformation
Overview
Item Description
Overview Reads the system configuration model information of the intelligent device station (remote head module).
Symbol
6
M+RJ71GF11_ReadSystemTypeInformation
(1) B: i_bEN o_bENO: B (5)
(2) DUT: i_stModule o_bOK: B (6)
(3) UW: i_u2TargetAddress o_bErr: B (7)
(4) UW: i_uChannel o_uErrId: UW (8)
o_uUnitTypeData: UW (9)
pbi_uResendCountMax (10)
pbi_uTimeUnit (11)
pbi_uMonitorTime (12)
pbo_uResendCount (13)
pbo_u4ErrTime (14)
pbo_uErrNetworkNo (15)
pbo_uErrStationNo (16)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_u2TargetAddress Target station Word Specifies the station number of the target station.
address [Unsigned]/ • 1st word: Network number
Bit String • 2nd word: Station number
[16-bit] (1) 0 (The setting is ignored.)
(0..1) (2) Station number
• 1 to 120: Intelligent device station (remote head module)
(4) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String specified by "Arrival monitoring time".
[16-bit] • 0 to 15
(11) pbi_uTimeUnit Arrival monitoring Word 0, 1 Specify the unit of the "Arrival monitoring time". 0
time unit [Unsigned]/ • 0: 1s
Bit String • 1: 100ms
[16-bit]
(12) pbi_uMonitorTime Arrival monitoring Word Specify the monitoring time until completion of processing. 0: 10s
time [Unsigned]/ If the processing is not completed within the monitoring
Bit String time, data is resent until the value specified in "Maximum
[16-bit] number of resends" is reached.
When "Arrival monitoring time unit" is set to 1s
• Effective range 1 to 32767: 1s to 32767s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
■Public variables
No. Variable name Name Data type Description Default
value
(13) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(14) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(15) pbo_uErrNetworkNo Error detection Word [Unsigned]/Bit The network number of the station in which an error was 0
network number String [16-bit] detected is stored.
(16) pbo_uErrStationNo Error-detected station Word [Unsigned]/Bit The station number of the station in which an error was 0
number String [16-bit] detected is stored.
• 125: Master station
• 1 to 120: Local station, intelligent device station, submaster
station
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
Name
■RJ71EN71, RnENCPU (network part)
This FB is displayed as follows on the engineering tool depending on the settings.
Name Module model name
RJ71EN71 RnENCPU (network part)
M+RJ71EN71_F_ReadSystemStatusInformation RJ71EN71(CCIEF) _RJ71EN71(CCIEF)
M+RJ71EN71_EF_ReadSystemStatusInformation RJ71EN71(E+CCIEF) _RJ71EN71(E+IEF)
■RJ71GF11-T2
M+RJ71GF11_ReadSystemStatusInformation
Overview
Item Description
Overview Reads the system configuration model status of the intelligent device station (remote head module).
Symbol
6
M+RJ71GF11_ReadSystemStatusInformation
(1) B: i_bEN o_bENO: B (5)
(2) DUT: i_stModule o_bOK: B (6)
(3) UW: i_u2TargetAddress o_bErr: B (7)
(4) UW: i_uChannel o_uErrId: UW (8)
o_uUnitStatusData: UW (9)
pbi_uResendCountMax (10)
pbi_uTimeUnit (11)
pbi_uMonitorTime (12)
pbo_uResendCount (13)
pbo_u4ErrTime (14)
pbo_uErrNetworkNo (15)
pbo_uErrStationNo (16)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_u2TargetAddress Target station Word Specifies the station number of the target station.
address [Unsigned]/ • 1st word: Network number
Bit String • 2nd word: Station number
[16-bit] (1) 0 (The setting is ignored.)
(0..1) (2) Station number
• 1 to 120: Intelligent device station (remote head module)
(4) i_uChannel Own station channel Word Specify the channel to be used by the own station.
[Unsigned]/ MELSEC iQ-R Programming Manual (Module Dedicated Instructions)
Bit String
[16-bit]
■Operation parameters
No. Variable name Name Data type Range Description Default
value
(10) pbi_uResendCountM Maximum number of Word 0 to 15 Specify the number of resends to be performed if the data 5
ax resends [Unsigned]/ transfer is not completed within the monitoring time
Bit String specified by "Arrival monitoring time".
[16-bit] • 0 to 15
(11) pbi_uTimeUnit Arrival monitoring Word 0, 1 Specify the unit of the "Arrival monitoring time". 0
time unit [Unsigned]/ • 0: 1s
Bit String • 1: 100ms
[16-bit]
(12) pbi_uMonitorTime Arrival monitoring Word Specify the monitoring time until completion of processing. 0: 10s
time [Unsigned]/ If the processing is not completed within the monitoring
Bit String time, data is resent until the value specified in "Maximum
[16-bit] number of resends" is reached.
When "Arrival monitoring time unit" is set to 1s
• Effective range 1 to 32767: 1s to 32767s
When "Arrival monitoring time unit" is set to 100ms
• Effective range 1 to 65535: 1 to 65535 100ms
■Public variables
No. Variable name Name Data type Description Default
value
(13) pbo_uResendCount Number of resends Word [Unsigned]/Bit The number of resends performed (result) is stored. 0
String [16-bit]
(14) pbo_u4ErrTime Error occurrence time Word [Unsigned]/Bit Clock data at the time of error occurrence is stored. 0
String [16-bit] (0..3) 1st word
• Upper 8 bits: Month (01H to 12H)
• Lower 8 bits: Lower 2 digits of year (00H to 99H)
2nd word
• Upper 8 bits: Hour (00H to 23H)
• Lower 8 bits: Day (01H to 31H)
3rd word
• Upper 8 bits: Second (00H to 59H)
• Lower 8 bits: Minute (00H to 59H)
4th word
• Upper 8 bits: Upper 2 digits of year (00H to 99H)
• Lower 8 bits: Day of week (00H (Sunday) to 06H (Saturday))
(15) pbo_uErrNetworkNo Error detection Word [Unsigned]/Bit The network number of the station in which an error was 0
network number String [16-bit] detected is stored.
(16) pbo_uErrStationNo Error-detected station Word [Unsigned]/Bit The station number of the station in which an error was 0
number String [16-bit] detected is stored.
• 125: Master station
• 1 to 120: Local station, intelligent device station, submaster
station
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
Name
■RJ71EN71, RnENCPU (network part)
M+RJ71EN71_RemoteReset
■RJ71GF11-T2
M+RJ71GF11_RemoteReset
Overview
Item Description
Overview Sends a remote STOP request to the target station and then sends a remote RESET request.
Symbol
M+RJ71GF11_RemoteReset
(1) B: i_bEN o_bENO: B (5)
(2) DUT: i_stModule o_bOK: B (6)
(3)
6
UW: i_uTargetNetworkNo o_bErr: B (7)
(4) UW: i_uTargetStationNo o_uErrId: UW (8)
pbo_u4ErrTime (9)
pbo_uErrNetworkNo (10)
pbo_uErrStationNo (11)
Labels
■Input arguments
No. Variable name Name Data type Range Description
(1) i_bEN Execution command Bit On: Start FB.
Off: Do not start FB.
(2) i_stModule Module label Structures Specify the module for which the FB is to be executed.
Specify the module label of the modules.
(3) i_uTargetNetworkNo Target network Word 1 to 239 Specify the network number of the target station.
number [Unsigned]/
Bit String
[16-bit]
(4) i_uTargetStationNo Target station Word Specifies the station number of the target station.
number [Unsigned]/ • 125: Master station
Bit String • 126: Master operating station
[16-bit] • 1 to 120: Local station, intelligent device station, remote device station,
submaster station
■Output arguments
No. Variable name Name Data type Description Default
value
(5) o_bENO Execution status Bit On: The execution command is turned on. Off
Off: The execution command is turned off.
(6) o_bOK Normal completion Bit The FB has been processed normally when this argument is on. Off
(7) o_bErr Error completion Bit The FB has been processed abnormally when this argument is on. Off
(8) o_uErrId Error code Word An error code is stored at error completion. 0
[Unsigned]/
Bit String
[16-bit]
FB details
Item Description
Available device Target module • RJ71EN71*1
• RJ71GF11-T2*1
• RnENCPU (network part)*1
CPU module RCPU
Engineering tool GX Works3*2
Language Ladder diagram
Number of basic 150 steps
steps The number of steps of the FB embedded in a program depends on the CPU module used, the input/output definitions, and the option
settings of GX Works3. For the option settings of GX Works3, refer to GX Works3 Operating Manual.
Processing When i_bEN (execution instruction) is turned on, this function sends a remote STOP request to the target station and then sends a remote
RESET request.
FB compilation Macro type
method
FB operation Pulse type (multiple-scan execution type)
Input condition for None
FB_EN
i_bEN
o_bENO
o_bOK
o_bErr
o_uErrId 0H
i_bEN
o_bENO 6
o_bOK
o_bErr
o_uErrId 0H (1) 0H
Error codes
Error code Reference
D000H to DFFFH MELSEC iQ-R CC-Link IE Field Network User's Manual (Application)
7.1 M+model_DeviceRead
The FB is the same as M+model_DeviceRead of the Ethernet-equipped module FB. ( Page 15 M+model_DeviceRead)
M M+RJ71EN71_EF_Send_Socket . . . . . . . . . . . . .62
M+RJ71EN71_EF_SetParameter . . . . . . . . . . . .195
M+RCPU_ConnectionClose . . . . . . . . . . . . . . . . 56 M+RJ71EN71_EF_StationNoSet . . . . . . . . . . . .181
M+RCPU_ConnectionOpen . . . . . . . . . . . . . . . . 51 M+RJ71EN71_EF_WriteTime . . . . . . . . . . . . . . .46
M+RCPU_Recv_Socket . . . . . . . . . . . . . . . . . . 59 M+RJ71EN71_F_DeviceRead . . . . . . . . . . . . . . . 15
M+RCPU_Send_Socket . . . . . . . . . . . . . . . . . . 62 M+RJ71EN71_F_DeviceWrite . . . . . . . . . . . . . . . 20
M+RCPU_SLMP_DeviceRead_IP . . . . . . . . . . . 67 M+RJ71EN71_F_ReadSystemStatusInformation
M+RCPU_SLMP_DeviceWrite_IP . . . . . . . . . . . . 73 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .213
M+RJ71BR11_DeviceRead . . . . . . . . . . . . . . . . 15 M+RJ71EN71_F_ReadSystemTypeInformation . .209
M+RJ71BR11_DeviceWrite . . . . . . . . . . . . . . . . 20 M+RJ71EN71_F_ReadTime . . . . . . . . . . . . . . . .42
M+RJ71BR11_ReadTime . . . . . . . . . . . . . . . . . 42 M+RJ71EN71_F_Recv . . . . . . . . . . . . . . . . . . . .32
M+RJ71BR11_Recv . . . . . . . . . . . . . . . . . . . . . 32 M+RJ71EN71_F_RemoteStopRun . . . . . . . . . . . .37
M+RJ71BR11_RemoteStopRun . . . . . . . . . . . . . 37 M+RJ71EN71_F_Send . . . . . . . . . . . . . . . . . . . .26
M+RJ71BR11_Send . . . . . . . . . . . . . . . . . . . . . 26 M+RJ71EN71_F_SetParameter . . . . . . . . . . . . .195
M+RJ71BR11_WriteTime . . . . . . . . . . . . . . . . . 46 M+RJ71EN71_F_StationNoSet . . . . . . . . . . . . .181
M+RJ71EN71_C_DeviceRead . . . . . . . . . . . . . . 15 M+RJ71EN71_F_WriteTime . . . . . . . . . . . . . . . .46
M+RJ71EN71_C_DeviceWrite . . . . . . . . . . . . . . 20 M+RJ71EN71_RemoteReset . . . . . . . . . . . . . . .217
M+RJ71EN71_C_ReadTime . . . . . . . . . . . . . . . 42 M+RJ71GF11_DeviceRead . . . . . . . . . . . . . . . . .15
M+RJ71EN71_C_Recv . . . . . . . . . . . . . . . . . . . 32 M+RJ71GF11_DeviceWrite . . . . . . . . . . . . . . . . .20
M+RJ71EN71_C_RemoteStopRun . . . . . . . . . . . 37 M+RJ71GF11_ReadSystemStatusInformation . . .213
M+RJ71EN71_C_Send . . . . . . . . . . . . . . . . . . . 26 M+RJ71GF11_ReadSystemTypeInformation . . . .209
M+RJ71EN71_C_StationNoSet . . . . . . . . . . . . 181 M+RJ71GF11_ReadTime . . . . . . . . . . . . . . . . . .42
M+RJ71EN71_C_WriteTime . . . . . . . . . . . . . . . 46 M+RJ71GF11_Recv . . . . . . . . . . . . . . . . . . . . . .32
M+RJ71EN71_EC_ConnectionClose . . . . . . . . . 56 M+RJ71GF11_RedundantSystem_GetAddress . .184
M+RJ71EN71_EC_ConnectionOpen . . . . . . . . . 51 M+RJ71GF11_RemoteReset . . . . . . . . . . . . . . .217
M+RJ71EN71_EC_DeviceRead . . . . . . . . . . . . . 15 M+RJ71GF11_RemoteStopRun . . . . . . . . . . . . . .37
M+RJ71EN71_EC_DeviceWrite . . . . . . . . . . . . . 20 M+RJ71GF11_Send . . . . . . . . . . . . . . . . . . . . . .26
M+RJ71EN71_EC_ReadTime . . . . . . . . . . . . . . 42 M+RJ71GF11_SetParameter . . . . . . . . . . . . . . .195
M+RJ71EN71_EC_Recv . . . . . . . . . . . . . . . . . . 32 M+RJ71GF11_SetParameterRedundant . . . . . . .201
M+RJ71EN71_EC_Recv_Socket . . . . . . . . . . . . 59 M+RJ71GF11_StationNoSet . . . . . . . . . . . . . . .181
M+RJ71EN71_EC_Refresh_Data . . . . . . . . . . . . 65 M+RJ71GF11_WriteTime . . . . . . . . . . . . . . . . . .46
M+RJ71EN71_EC_RemoteStopRun . . . . . . . . . . 37 M+RJ71GN11_DeviceRead . . . . . . . . . . . . . . . . .79
M+RJ71EN71_EC_Send . . . . . . . . . . . . . . . . . . 26 M+RJ71GN11_DeviceWrite . . . . . . . . . . . . . . . . .84
M+RJ71EN71_EC_Send_Socket . . . . . . . . . . . . 62
M+RJ71EN71_EC_StationNoSet . . . . . . . . . . . 181
M+RJ71GN11_Recv . . . . . . . . . . . . . . . . . . . . . .97
M+RJ71GN11_RemoteRead . . . . . . . . . . . . . . .132
I
M+RJ71EN71_EC_WriteTime . . . . . . . . . . . . . . 46 M+RJ71GN11_RemoteReset2_IP . . . . . . . . . . .147
M+RJ71EN71_EE_ConnectionClose . . . . . . . . . 56 M+RJ71GN11_RemoteReset_IP . . . . . . . . . . . .142
M+RJ71EN71_EE_ConnectionOpen . . . . . . . . . . 51 M+RJ71GN11_RemoteStopRun . . . . . . . . . . . .102
M+RJ71EN71_EE_DeviceRead . . . . . . . . . . . . . 15 M+RJ71GN11_RemoteWrite . . . . . . . . . . . . . . .137
M+RJ71EN71_EE_DeviceWrite . . . . . . . . . . . . . 20 M+RJ71GN11_SE_ConnectionClose . . . . . . . . .165
M+RJ71EN71_EE_ReadTime . . . . . . . . . . . . . . 42 M+RJ71GN11_SE_ConnectionOpen . . . . . . . . .162
M+RJ71EN71_EE_Recv . . . . . . . . . . . . . . . . . . 32 M+RJ71GN11_SE_DeviceRead . . . . . . . . . . . . . .79
M+RJ71EN71_EE_Recv_Socket . . . . . . . . . . . . 59 M+RJ71GN11_SE_DeviceWrite . . . . . . . . . . . . . .84
M+RJ71EN71_EE_Refresh_Data . . . . . . . . . . . . 65 M+RJ71GN11_Send . . . . . . . . . . . . . . . . . . . . . .91
M+RJ71EN71_EE_RemoteStopRun . . . . . . . . . . 37 M+RJ71GN11_SE_Recv . . . . . . . . . . . . . . . . . . .97
M+RJ71EN71_EE_Send . . . . . . . . . . . . . . . . . . 26 M+RJ71GN11_SE_Recv_Socket . . . . . . . . . . . .167
M+RJ71EN71_EE_Send_Socket . . . . . . . . . . . . 62 M+RJ71GN11_SE_Refresh_Data . . . . . . . . . . .172
M+RJ71EN71_EE_WriteTime . . . . . . . . . . . . . . 46 M+RJ71GN11_SE_RemoteRead . . . . . . . . . . . .132
M+RJ71EN71_EF_ConnectionClose . . . . . . . . . 56 M+RJ71GN11_SE_RemoteReset2_IP . . . . . . . .147
M+RJ71EN71_EF_ConnectionOpen . . . . . . . . . . 51 M+RJ71GN11_SE_RemoteReset_IP . . . . . . . . .142
M+RJ71EN71_EF_DeviceRead . . . . . . . . . . . . . 15 M+RJ71GN11_SE_RemoteStopRun . . . . . . . . .102
M+RJ71EN71_EF_DeviceWrite . . . . . . . . . . . . . 20 M+RJ71GN11_SE_RemoteWrite . . . . . . . . . . . .137
M+RJ71EN71_EF_ReadSystemStatusInformation M+RJ71GN11_SE_Send . . . . . . . . . . . . . . . . . . .91
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213 M+RJ71GN11_SE_Send_Socket . . . . . . . . . . . .170
M+RJ71EN71_EF_ReadSystemTypeInformation M+RJ71GN11_SE_SLMP_DeviceRead_IP . . . . .108
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209 M+RJ71GN11_SE_SLMP_DeviceWrite_IP . . . . .115
M+RJ71EN71_EF_ReadTime . . . . . . . . . . . . . . 42 M+RJ71GN11_SetAddress . . . . . . . . . . . . . . . .122
M+RJ71EN71_EF_Recv . . . . . . . . . . . . . . . . . . 32 M+RJ71GN11_SetParameterX . . . . . . . . . . . . .125
M+RJ71EN71_EF_Recv_Socket . . . . . . . . . . . . 59 M+RJ71GN11_SLMP_DeviceRead_IP . . . . . . . .108
M+RJ71EN71_EF_Refresh_Data . . . . . . . . . . . . 65 M+RJ71GN11_SLMP_DeviceWrite_IP . . . . . . . .115
M+RJ71EN71_EF_RemoteStopRun . . . . . . . . . . 37 M+RJ71GN11_SX_DeviceRead . . . . . . . . . . . . . .79
M+RJ71EN71_EF_Send . . . . . . . . . . . . . . . . . . 26 M+RJ71GN11_SX_DeviceWrite . . . . . . . . . . . . . .84
229
M+RJ71GN11_SX_Recv . . . . . . . . . . . . . . . . . . 97
M+RJ71GN11_SX_RemoteReset2_IP . . . . . . . 147
M+RJ71GN11_SX_RemoteReset_IP . . . . . . . . 142
M+RJ71GN11_SX_RemoteStopRun . . . . . . . . . 102
M+RJ71GN11_SX_Send . . . . . . . . . . . . . . . . . . 91
M+RJ71GN11_SX_SetAddress . . . . . . . . . . . . 122
M+RJ71GN11_SX_SLMP_DeviceRead_IP . . . . 108
M+RJ71GN11_SX_SLMP_DeviceWrite_IP . . . . 115
M+RJ71GP21_DeviceRead . . . . . . . . . . . . . . . . 15
M+RJ71GP21_DeviceWrite . . . . . . . . . . . . . . . . 20
M+RJ71GP21_ReadTime . . . . . . . . . . . . . . . . . 42
M+RJ71GP21_Recv . . . . . . . . . . . . . . . . . . . . . 32
M+RJ71GP21_RedundantSystem_GetAddress
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184
M+RJ71GP21_RemoteStopRun . . . . . . . . . . . . . 37
M+RJ71GP21_Send . . . . . . . . . . . . . . . . . . . . . 26
M+RJ71GP21_StationNoSet . . . . . . . . . . . . . . 181
M+RJ71GP21_WriteTime . . . . . . . . . . . . . . . . . 46
M+RJ71LP21_DeviceRead . . . . . . . . . . . . . . . . 15
M+RJ71LP21_DeviceWrite . . . . . . . . . . . . . . . . 20
M+RJ71LP21_ReadTime . . . . . . . . . . . . . . . . . . 42
M+RJ71LP21_Recv . . . . . . . . . . . . . . . . . . . . . 32
M+RJ71LP21_RedundantSystem_GetAddress
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184
M+RJ71LP21_RemoteStopRun . . . . . . . . . . . . . 37
M+RJ71LP21_Send . . . . . . . . . . . . . . . . . . . . . 26
M+RJ71LP21_WriteTime . . . . . . . . . . . . . . . . . . 46
230
REVISIONS
*The manual number is given on the bottom left of the back cover.
Revision date *Manual number Description
June 2014 BCN-P5999-0381-A First edition
July 2014 BCN-P5999-0381-B Partial correction
November 2014 BCN-P5999-0381-C ■Added function
CC-Link IE Controller Network function of the RJ71EN71
■Added or modified parts
Section 2.1, 2.2, 3.3, 4.1, 5.1
July 2015 BCN-P5999-0381-D ■Added or modified parts
Section 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 3.1, 3.2, 3.3, 3.4, 3.5, 4.1, 5.1
January 2016 BCN-P5999-0381-E ■Added or modified parts
Chapter 1, Section 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 4.1, 5.1
May 2016 BCN-P5999-0381-F ■Added or modified parts
Chapter 1, Section 4.2, 5.3, 5.4, 5.5
April 2017 BCN-P5999-0381-G ■Added or modified parts
Section 3.6, 3.7, 5.6
April 2018 BCN-P5999-0381-H ■Added or modified parts
Section 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 4.1, 4.2, 5.1, 5.4, 5.5, 5.6
May 2019 BCN-P5999-0381-I ■Added model
RJ71GN11-T2
■Added or modified parts
Chapter 1, 2, 3, 4, 5, TRADEMARK
May 2019 BCN-P5999-0381-J ■Added or modified part
Chapter 3
October 2019 BCN-P5999-0381-K ■Added or modified part
Section 3.9
November 2019 BCN-P5999-0381-L ■Added or modified parts
Section 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 3.9, 3.10, 3.11
February 2020 BCN-P5999-0381-M ■Added model
RJ71LP21-25
■Added or modified parts
Chapter 1, Section 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.10, 2.13, 2.14, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6,
3.7, 3.9, 3.10, 3.11, 4.9, 5.11, 5.12, Chapter 6
March 2020 BCN-P5999-0381-N ■Added or modified part
RELEVANT MANUALS
April 2021 BCN-P5999-0381-O ■Added or modified parts
Section 2.1, 2.2, 2.3, 2.4, 2.10, 2.11
August 2021 BCN-P5999-0381-P ■Added or modified parts
Chapter 1, Section 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 2.10, 2.11, 2.12, 2.13, 2.14, 3.1, 3.2, 3.3,
3.4, 3.5, 3.6, 3.7, 3.8, 3.9, 3.10, 3.11, 3.12, 4.8, 4.9, 5.8, 5.11, 5.12, 5.13
October 2021 BCN-P5999-0381-Q ■Added or modified parts
Section 1.1, 5.9
January 2022 BCN-P5999-0381-R ■Added model
RJ71GN11-EIP
■Added or modified parts
INTRODUCTION, RELEVANT MANUALS, Section 1.1, 1.3, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 3.8, 3.10,
3.11, 3.12, Chapter 4
■Chapter number change
Chapter 4 to 6 Chapter 5 to 7
April 2022 BCN-P5999-0381-S ■Added or modified parts
Section 1.1, 3.5, 3.6, 3.7, 3.9, 3.12, 3.13, 4.11
April 2023 BCN-P5999-0381-T ■Added models
RJ71GN11-SX, RJ71BR11
■Added or modified parts
INTRODUCTION, Section 1.1, 1.3, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.8, 3.9,
3.12, 3.13
231
TRADEMARKS
The company names, system names and product names mentioned in this manual are either registered trademarks or
trademarks of their respective companies.
In some cases, trademark symbols such as '' or '' are not specified in this manual.
232 BCN-P5999-0381-T
BCN-P5999-0381-T(2304)
HEAD OFFICE: TOKYO BLDG., 2-7-3, MARUNOUCHI, CHIYODA-KU, TOKYO 100-8310, JAPAN
NAGOYA WORKS: 1-14, YADA-MINAMI 5-CHOME, HIGASHI-KU, NAGOYA 461-8670, JAPAN
When exported from Japan, this manual does not require application to the
Ministry of Economy, Trade and Industry for service transaction permission.