Question: 168.255.0 to 192.168.255.255

Answer:
• Due to Ethernet restrictions, you cannot specify the following IP addresses.
a) An IP address that is all 0's or all 1's
b) IP addresses that start with 127, 0, or 255 (decimal)
c) IP addresses that have a host ID that is all 0's or all 1's
d) Class-D IP addresses (224.0.0.0 to 239.255.255.255)
e) Class-E IP addresses (240.0.0.0 to 255.255.255.255)
 Connecting from a Saved Project
The connection configuration that is set (via USB or EtherNet/IP) is saved in the project.
When you open a saved project on the Sysmac Studio, you can connect to the EtherNet/IP network
without redoing the settings.
5-10 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Checking the Current IP Address
The current IP address can be confirmed in the Controller Status Pane of the Sysmac Studio, whether
it is manually set or obtained from the BOOTP server.
Display when using the NJ-series CPU Units and NX1P2 CPU Units
• Basic Controller Status Pane • Controller Status Pane with Details
Display when using the NX701 CPU Units, NX502 CPU Units, and NX102 CPU Units
• Basic Controller Status Pane • Controller Status Pane with Details
Additional Information
• If the IP address of the built-in EtherNet/IP port is not registered due to the following reasons,
the IP address field shows "0.0.0.0".
• The IP address was not obtained from the BOOTP server or DHCP server.
• The built-in EtherNet/IP port on the NX701 CPU Unit, NX502 CPU Unit, or NX102 CPU
Unit is disabled. Refer to 4-1 TCP/IP Settings Display on page 4-2 for details on the set-
tings for the IP address of the built-in EtherNet/IP port.
5-1-3 Private and Global Addresses
Private and Global Addresses
There are two kinds of IP addresses, private and global.
Global address These are IP addresses that connect directly to the Internet. Allocated by applica-
tion to NIC, each address is unique in the world, and as many as 4.3 billion can be
allocated worldwide.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-11
5-1
Determining
IP
Addresses
5
5-1-3
Private
and
Global
Addresses
5 TCP/IP Functions
Private address These are IP addresses for Intranet (LAN) use. Direct connection to the Internet is
not possible. Frames that include private IP addresses are restricted by the router
from being sent outside the LAN.
Generally, as shown below, global addresses in the intranet are allocated only to IP routers (such as
broadband routers) interfaced with the Internet. All other nodes in the intranet, which includes the built-
in EtherNet/ IP port, are allocated private addresses.
Intranet
Personal computer
(e.g., Sysmac Studio)
Ethernet (EtherNet/IP)
Firewall Controller
Private address
IP router
Private address
Cannot connect to Internet
Internet
Global address (required)
Intranet Cannot connect to Internet
Global address
IP router Private address
Private address Personal computer
(e.g., Sysmac Studio)
Firewall
Ethernet (EtherNet/IP)
Controller Controller
Private address Private address
5-12 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Using a Private Address for the Built-in EtherNet/IP Port
Intranet
Personal computer
(e.g., Sysmac Studio)
Ethernet (EtherNet/IP)
Firewall Controller
Private address
IP router
Private address
Cannot connect to Internet
Internet
Global address (required)
Intranet Cannot connect to Internet
Global address
IP router Private address
Private address Personal computer
(e.g., Sysmac Studio)
Firewall
Ethernet (EtherNet/IP)
Controller Controller
Private address Private address
Conditions for Communications Applications
¢
If the built-in EtherNet/IP port uses a private address, you can use explicit message communi-
cations service under the following conditions.
• The explicit message communications service can be executed on the intranet between built-
in EtherNet/IP ports with private addresses only.
• A device such as a personal computer (CIP applications including the Network Configurator)
cannot connect online and communicate over the Internet with a built-in EtherNet/IP port that
has a private address.
Explicit message communications are also not possible over the Internet between built-in
EtherNet/IP ports with private addresses.
Precautions for Correct Use
• To set up an intranet through a global address involves network security considerations. Be
sure to consult with a network specialist in advance and consider installation of a firewall.
• Some communication applications may not be available depending on the firewall settings
made by the communications company. If there are communication applications that cannot
be used, be sure to check with your communications company.
• When sending and receiving data over a global address, use secure communications, such
as secure socket communications and OPC UA, that ensure confidentiality and integrity.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-13
5-1
Determining
IP
Addresses
5
5-1-3
Private
and
Global
Addresses
5 TCP/IP Functions
Using a Global Address for the Built-in EtherNet/IP Port
Intranet
CIP client on a computer,
such as Network
Configurator
Ethernet (EtherNet/IP)
Communications Firewall
over Internet
Private address
IP router
Cannot connect to Internet
Internet
Global address (required)
Intranet Cannot connect to Internet
Global address
IP router
Private address
Private address
Firewall
Ethernet (EtherNet/IP)
Communications Controller
in intranet
Built-in EtherNet/IP port: Global address
Conditions for Communications Applications
¢
You can use the explicit message communications service over the Internet under the following
conditions.
• A device such as a personal computer (a CIP application including the Network Configurator)
can connect online and communicate over the Internet with a built-in EtherNet/IP port that has
a global address.
• The TCP port number (44818) or UDP port number (44818) that is used for EtherNet/IP can-
not be used because it is prohibited by a firewall in the communications path.
Precautions for Correct Use
• To set a global IP address for a built-in EtherNet/IP port involves network security considera-
tions. It is recommended that the user contract with a communications company for a dedi-
cated line, rather than for a general line such as a broadband line. Also, be sure to consult
with a network specialist and consider security measures such as a firewall.
• Some communication applications may not be available depending on the firewall settings
made by the communications company. If there are communication applications that cannot
be used, be sure to check with your communications company.
• When sending and receiving data over a global address, use secure communications, such
as secure socket communications and OPC UA, that ensure confidentiality and integrity.
5-14 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
5-2 Default States of TCP/UDP Ports and
the Changing Procedure
The following table shows the applications that use TCP/UDP ports for which a user can change the
port state, CPU Unit models, port numbers, default port states, usages, and how to change a port from
open to close and close to open.
Refer to A-12 TCP/ UDP Port Numbers Used for the Built-in EtherNet/IP Port on page A-95 for infor-
mation on all TCP/UDP ports of the built-in EtherNet/IP port.
UDP TCP
Default
Applica- port port How to change from How to change from
CPU Unit model port Usage
tion num- num- open to close close to open
state
ber ber
FTP All models --- 20 Close Used On the Sysmac Studio, On the Sysmac Studio,
server --- 21 Close when select Built-in select Built-in
using EtherNet/IP Port EtherNet/IP Port
the FTP Settings - FTP Settings - FTP
server. Settings, and then se- Settings, and then se-
lect Do not use for FTP lect Use for FTP
server. server.
SNMP All models 161 --- Close Used On the Sysmac Studio, On the Sysmac Studio,
when select Built-in select Built-in
using EtherNet/IP Port EtherNet/IP Port
the Settings - SNMP Settings - SNMP
SNMP Settings, and then se- Settings, and then se-
agent. lect Do not use for lect Use for SNMP
SNMP service. service.
HTTPS All models --- 443 Open Used for Make one of the follow- • Use the Packet Filter.
server commu- ing settings. • Do not set the DIP
nica- • Use the Packet Filter. switch to enable
tions *1 connections to the
with the • Set the DIP switch to Sysmac Studio and
Sysmac enable connections to NA that are not
Studio. the Sysmac Studio supporting secure
and NA that are not communication. *6
supporting secure
communication. *1*6
FINS/U • All NJ-series 9600 --- Open Used for On the Sysmac Studio, On the Sysmac Studio,
DP models the select Built-in select Built-in
• All NX1P2 CPU FINS/ EtherNet/IP Port EtherNet/IP Port
Unit models UDP. Settings - FINS Settings - FINS
• All NX102 CPU Settings, and then se- Settings, and then se-
Unit models*2 lect Do not use for lect Use for FINS/UDP.
FINS/UDP.
• NX701-1£20*2
• All NX502 CPU
Unit models*2
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-15
5-2
Default
States
of
TCP/UDP
Ports
and
the
Changing
Procedure
5
5 TCP/IP Functions
UDP TCP
Default
Applica- port port How to change from How to change from
CPU Unit model port Usage
tion num- num- open to close close to open
state
ber ber
FINS/TC • All NJ-series --- 9600 Open Used for On the Sysmac Studio, On the Sysmac Studio,
P models the select Built-in select Built-in
• All NX102 CPU FINS/ EtherNet/IP Port EtherNet/IP Port
Unit models*2 TCP. Settings - FINS Settings - FINS
Settings, and then se- Settings, and then se-
• NX701-1£20*2
lect Do not use for lect Use for FINS/TDP.
• All NX502 CPU
FINS/TCP.
Unit models*2
Sysmac All models 9600 --- Open Used for Use the Packet Filter. *1 Use the Packet Filter.
Studio CPU Unit with a 2224 --- Close*4 commu-
USB port nica-
• All NJ-series tions
models with the
• All NX701 CPU Sysmac
Studio.
Unit models*3
CIP All models 44818 44818 Open Used for On the Sysmac Studio, On the Sysmac Studio,
messag- the CIP select Built-in select Built-in
es messag- EtherNet/IP Port EtherNet/IP Port
es. Settings - CIP Settings - CIP
Settings, and then se- Settings, and then se-
lect Do not use for CIP lect Use for CIP
Message Server. Message Server.
OPC UA CPU Units that sup- --- 4840 Close Used On the Sysmac Studio, On the Sysmac Studio,
port OPC UA when select OPC UA select OPC UA
• NJ501-1£00 using Settings - OPC UA Settings - OPC UA
• All NX102 CPU the OPC Server Settings - Server Settings -
Unit models*5 UA. Server Settings, and Server Settings, and
then select Do not use then select Use for
• NX701-1£££*5
for OPC UA Server. OPC UA Server.
• All NX502 CPU
Unit models*5
TCP/UD CPU Units that sup- 64000 64000 Close Used On the Sysmac Studio, On the Sysmac Studio,
P mes- port TCP/UDP mes- when select Built-in select Built-in
sage sage service using EtherNet/IP Port EtherNet/IP Port
service • All NX102 CPU the Settings - TCP/UDP Settings - TCP/UDP
Unit models TCP/UD Message Service Message Service
• All NX502 CPU P mes- Settings, and then se- Settings, and then se-
Unit models sage lect Do not use for lect Use for TCP/UDP
service. TCP/UDP message message service.
service.
*1. Closing the port may prevent communications with the Sysmac Studio. Refer to Troubleshooting When You Cannot Go
Online from the Sysmac Studio in the NJ/NX-series Troubleshooting Manual (Cat. No. W503) on how to make correc-
tions.
*2. This port number is supported only on Port 2. It cannot be used on Port 1.
*3. Only if the CPU Unit has a USB port.
*4. Always closed for the built-in EtherNet/IP port. Opened for the USB port only.
*5. This port number is supported only on Port 1. It cannot be used on Port 2.
*6. The NX502 CPU Units do not have this setting.
5-16 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Precautions for Correct Use
When using socket service instructions, specify the port number so that the port numbers used
do not overlap. If the port numbers used are duplicated, an error will occur during instruction
execution.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-17
5-2
Default
States
of
TCP/UDP
Ports
and
the
Changing
Procedure
5
5 TCP/IP Functions
5-3 Testing Communications
If the basic settings (in particular the IP address and subnet mask) have been made correctly for the
built-in EtherNet/IP port, then it is possible to communicate with nodes on the EtherNet/IP network.
This section describes how to use the PING command to test communications with the built-in Ether-
Net/IP port.
5-3-1 PING Command
The PING command sends an echo request packet to a remote node and receives an echo response
packet to confirm that the remote node communications are normal. The PING command uses the
ICMP echo request and response. The echo response packet is automatically returned in the ICMP.
The PING command is normally used to check the connections of remote nodes when you set up a
network. The built-in EtherNet/IP port supports both the ICMP echo request and response functions.
If the remote node returns a normal response to the PING command, then the node is physically con-
nected correctly and Ethernet node settings are correct.
Remote node
(e.g., host computer)
Built-in EtherNet/IP port
TCP UDP
ICMP IP
Ethernet
Echo request
Echo response
5-3-2 Using the PING Command
The built-in EtherNet/IP port automatically returns an echo response packet in response to an echo
request packet sent by another node (e.g., host computer).
Precautions for Correct Use
When the Use Option is selected for Packet Filter of the built-in EtherNet/IP port, PING com-
mand cannot be received unless icmp is selected for Protocol of Pacekt Filter settings. For the
details on the settings, refer to Packet Filter on page 4-8.
5-3-3 Host Computer Operation
The PING command can be executed from the host computer to send an echo request packet to a
built-in EtherNet/IP port.
The following example shows how to use the PING command in the host computer.
5-18 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Application Method
Input the following command at the host computer's prompt ($):
$ ping IP_address (host_name)
The destination is specified by its IP address or host name.
Additional Information
The PING command is not supported by some host computers.
Application Example
In this example, a PING command is sent to the node at IP address 130.25.36.8.
The "$" in the example represents the host computer prompt.
 Normal Execution
$ ping 130.25.36.8 Executes the PING command.
PING 130.25.36.8: 56 data bytes
64 bytes from 130.25.36.8: icmp_seq=0. time=0. ms
64 bytes from 130.25.36.8: icmp_seq=0. time=0. ms
: : : : :
64 bytes from 130.25.36.8: icmp_seq=0. time=0. ms
Press the Ctrl+C Keys to cancel execution.
---- 130.25.36.8 PING Statistics ----
9 packets transmitted, 9 packets received, 0% packets loss
round-trip ms min/avg/max = 0/1/16
$
 Error
$ ping 130.25.36.8 Executes the PING command.
PING 130.25.36.8: 56 data bytes
Press the Ctrl+C Keys to cancel execution.
---- 130.25.36.8 PING Statistics ----
9 packets transmitted, 0 packets received, 100% packets loss
$
Refer to the command reference manual for your computer's OS for details on using the PING
command.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-19
5-3
Testing
Communications
5
5-3-3
Host
Computer
Operation
5 TCP/IP Functions
5-4 Packet Filter
This section provides an overview of Packet Filter, explains the specifications, settings, and usage ex-
amples.
5-4-1 Introduction to Packet Filter
This function filters IP packets in the receive processing at the built-in EtherNet/IP ports. While Packet
Filter (Simple) is used to restrict Sysmac Studio connections, Packet Filter performs general-purpose
packet filtering that does not restrict communication partner to Sysmac Studio.
Packet Filter settings are configured in the permit list. If any is set in Packet Filter, all packets are al-
lowed. If a value other than any is set in Packet Filter, the received packet is compared with Packet
Filter settings. When a matching packet is received, reception is permitted. When a non-matching
packet is received, reception is prohibited and the packet is discarded. Packet Filter settings include
the source IP address, destination IP address, and TCP/UDP port number.
Support software or a device
Ethernet
Packet
Source IP address Destination IP address Source port Destination port
Compare packets in order from No.1 in the list.
If matched: allow to receive the packet
If not matched: reject reception and discard the packet
EtherNet/IP port Packet Filter settings
No. Source IP address Destination IP address Source port Destination port
1 *.*.*.* *.*.*.* *** ***
Packet Filter function
2 *.*.*.* *.*.*.* *** ***
: : : :
Precautions for Correct Use
• If you use an NX701 CPU Unit, NX502 CPU Unit, NX102 CPU Unit, or NX1P2 CPU Unit and
cannot go online with the Sysmac Studio because of forgetting the registered IP address, you
can disable this function tentatively by starting the Unit in Safe Mode. Refer to
Troubleshooting When You Cannot Go Online from the Sysmac Studio in the NJ/NX-series
Troubleshooting Manual (Cat. No. W503) for details.
• If you use an NJ-series CPU Unit and cannot go online with the Sysmac Studio because of
forgetting the registered IP address, connect using the USB port.
• Packet Filter supports the stateful inspection. Therefore, if the Controller is specified as a cli-
ent, as in DNS, NTP, DB connection services, and communication instructions, you do not
need to add the responses from other devices to Packet Filter settings. For example, if you
execute the FTP client instruction of the Controller, you can receive responses from the FTP
server through stateful inspection even if you have not registered the response from the FTP
server in Packet Filter settings.
5-20 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Version Information
Packet Filter is available in the following CPU Units of the stated versions.
• NJ-series, NX102, NX1P2 CPU Unit: Version 1.49 or later
• NX701 CPU Unit: Version 1.29 or later
• NX502 CPU Unit: Version 1.60 or later
5-4-2 Packet Filter Specifications
The specifications for Packet Filter are given below.
Item Specification Remarks
Filtering system Permit list The system enables reception of
packets registered in Packet Filter
settings and prohibits reception of
unregistered packets.
Location to perform filtering Receive processing at the built-in • No filtering is applied to the
EtherNet/IP port sending process of the built-in
(If the Controller has two built-in EtherNet/IP port.
EtherNet/IP ports, you can config- • Stateful inspection is supported.
ure the setting for each port.)
Number of Packet Filter tables 32
Settings for Packet Filter tables • Source IP Address/Mask Range specification can be set for
• Destination IP Address/Mask the IP address and TCP/UDP ports.
• Protocol (tcp, udp, igmp, icmp)
If tcp or udp is selected for Proto-
col, specify the source port and
destination port.
5-4-3 Packet Filter Settings
For details on Packet Filter settings, refer to Packet Filter on page 4-8.
Additional Information
For set values of Destination Port for each communication, refer to 5-4-5 Settings for Devices
That Access the Controller on page 5-33.
5-4-4 Case Where Packet Filter Is Used
Packets sent from a computer or a device to the Controller include the following four types of informa-
tion.
• Source IP address
Unique numbers assigned to each source device. This address can be used to identify the source
device.
• Destination IP address
Unique numbers assigned to each Controller that is the destination. This address can be used to
identify the Controller to which the packets are sent.
• Source port
A unique number assigned to the source application. This number can be used to identify the source
application.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-21
5-4
Packet
Filter
5
5-4-2
Packet
Filter
Specifications
5 TCP/IP Functions
• Destination port
A unique number assigned to the destination application. This number can be used to identify the
application to which the packets are sent.
Source device Controller
Application Source port FTP server Destination port
Application Source port SNMP server Destination port
Application Source port CIP message server Destination port
: : : :
Packet Filter function
(1) Filtering by source IP address Allow reception
(2) Filtering by destination IP address
(3) Filtering by source port
Prohibit reception
(4) Filtering by destination port
Source IP address Destination IP address
Packet
Source IP address Destination IP address Source port Destination port
Packet Filter function can enable or disable the reception of packets using these four types of informa-
tion. If the content of the packet matches the permitted content in Packet Filter settings, reception is
permitted. Otherwise, reception is disabled and the packet is discarded.
In the case where Packet Filter is used, the four types of information are related as follows.
Case where Packet Filter
Description Reference
is used
(1) Filtering by source IP Enables or disables reception of packets Case 1: Filtering by Source IP Ad-
address sent from a specific device. dress on page 5-23
(2) Filtering by destination Only packets sent to a specific Controller Case 2: Filtering by Destination IP
IP address are allowed to be received. Address on page 5-25
(3)Filtering by source port Allow or disallow packets sent using a spe- Case 3: Filtering by Source Port on
cific application. page 5-29
(4)Filtering by destination Allow and receive only packets sent to a Case 4: Filtering by Destination
port specific application. Port on page 5-31
Packet Filter settings can also be set as shown below according to the case where the four types of
Packet Filter are used.
(1) Filtering by source IP address (2) Filtering by destination IP address (3) Filtering by source port (4) Filtering by destination port
Case 1 Case 2 Case 3 Case 4
The following describes usage examples and set values for each of the four types of cases.
5-22 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Case 1: Filtering by Source IP Address
You can filter access to the Controller by source IP address. This is useful when the IP address can be
used to distinguish client devices that are prohibited from communicating with client devices that are
permitted to communicate. In Packet Filter’s source IP address setting, set the IP address of the de-
vice that is allowed to communicate. Communications with devices whose IP addresses are not regis-
tered are prohibited.
 Application Example
An application example under the following conditions is shown below.
• Communications between the computer used in the facility and the Controller are permitted, and
communications with a computer brought without permission are prohibited.
• The IP addresses of the computers that are permitted to communicate are fixed.
• The computers that are allowed to communicate have Sysmac Studio and OPC UA respectively.
The configuration of this application example is as follows.
A computer brought without permission
Sysmac Studio Sysmac Studio OPC UA
IP address:192.168.250.100/24 IP address:192.168.250.2/24 IP address:192.168.250.3/24
Ethernet
Prohibited Permitted
NJ-series CPU Unit
Packet Filter settings are as follows. Enter the IP address of the computer to use Sysmac Studio in
the No.1 Source IP Address field. Enter the IP address of the computer to use OPC UA in the
No.2 Source IP Address field.
No. Setting Set value
1 Source IP Address Specification Method IP address specification
IP Address 192.168.250.2
Mask 255.255.255.255
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-23
5-4
Packet
Filter
5
5-4-4
Case
Where
Packet
Filter
Is
Used
5 TCP/IP Functions
No. Setting Set value
2 Source IP Address Specification Method IP address specification
IP Address 192.168.250.3
Mask 255.255.255.255
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Additional Information
You can also mask the IP address to specify multiple devices that are allowed to communicate.
The following is sample Packet Filter settings to allow communications with devices with IP ad-
dresses from 192.168.250.1 to 192.168.250.3.
No. Setting Set value
1 Source IP Address Specification Method IP address specification
IP Address 192.168.250.0
Mask 255.255.255.252
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
 Restrictions
When filtering by the source IP address is used, communication from devices that are not regis-
tered to the source IP address of Packet Filter settings is prohibited. Therefore, the IP addresses of
all devices communicating with the Controller must be registered to the source IP addresses.
If the Controller cannot communicate with a device that you want to allow, make sure that the IP
address of that device is correctly set to the source IP address.
5-24 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Case 2: Filtering by Destination IP Address
You can filter access to the Controller by destination IP address in the packets received by the built-in
EtherNet/IP port. This is useful in the following cases.
• Where you want to prohibit the receipt of broadcast packets that are unnecessary for the Controller
• Where you want to prohibit direct connection via Ethernet in the Sysmac Studio, but allow connec-
tion by a specified IP address
 Application Example 1
An application example under the following conditions is shown below.
• Reception of unnecessary broadcast packets for the Controller is prohibited.
• Connection of Sysmac Studio through Ethernet connection via a hub is allowed and connec-
tion through Direct connection via Ethernet is prohibited.
The configuration of this application example is as follows. Destination IP address for direct con-
nection via Ethernet is 169. 254.***.***. Destination IP address of unnecessary broadcast packets
for the Controller is 192.168.250.255.
Sysmac Studio
Ethernet connection via a hub Broadcast packet
Destination IP address:192.168.250.255
Destination IP address:192.168.250.1
Sysmac Studio
Prohibited Ethernet Permitted
Destination IP address:169.254.***.***
Direct connection via Ethernet
Prohibited
NJ-series CPU Unit
IP address:192.168.250.1/24
Packet Filter settings are as follows. Set the IP address for the Controller's built-in EtherNet/IP port
to the destination IP address.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-25
5-4
Packet
Filter
5
5-4-4
Case
Where
Packet
Filter
Is
Used
5 TCP/IP Functions
No. Setting Set value
1 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method IP address specification
IP Address 192.168.250.1
Mask 255.255.255.255
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
 Application Example 2
If filtering by destination IP address is enabled in a Controller between devices, it can restrict the
devices that are allowed to communicate with each other.
An application example under the following conditions is shown below.
• Controller A has two built-in EtherNet/IP ports.
• Port 1 of Controller A is connected to the information network, and the computer with Sysmac
Studio and the computer using Database are connected to the information network.
• Port 2 of Controller A is connected to the control network, and Controller B and Controller C are
connected to the control network.
• The computer with Sysmac Studio communicates only with Controller A and Controller B. The
computer using Database only communicates with Controller C.
The configuration of this application example is as follows.
Sysmac Studio Database
IP address:192.168.250.200/24 IP address:192.168.250.100/24
Ethernet
Permitted Controller A
Information network
(Built-in EtherNet/IP Port 1) Port 1 IP address:192.168.250.1/24
Port 2 IP address:192.168.251.1/24
Control network
(Built-in EtherNet/IP Port 2)
Permitted
NX701 or NX102 CPU Unit
Ethernet
Controller B Controller C
NJ-series CPU Unit NJ-series CPU Unit
IP address:192.168.251.2/24 IP address:192.168.251.3/24
5-26 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Packet Filter settings of Controller A are as follows.
Enter the IP address of Controller A and Controller B to Destination IP Address field.
Enter the IP address of the computer using Database to Port 2 Destination IP Address field.
Port 1 Packet Filter Settings
No. Setting Set value
1 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method IP address specification
IP Address 192.168.251.2
Mask 255.255.255.255
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
2 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method IP address specification
IP Address 192.168.250.1
Mask 255.255.255.255
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Port 2 Packet Filter Settings
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-27
5-4
Packet
Filter
5
5-4-4
Case
Where
Packet
Filter
Is
Used
5 TCP/IP Functions
No. Setting Set value
1 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method IP address specification
IP Address 192.168.250.100
Mask 255.255.255.255
Protocol any
Source Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method ---
Range Specification ---
Start Number ---
End Number ---
To route different networks, the computers, Controller B, and Controller C must be configured with
a default gateway or an IP router table.
 Restrictions
When filtering by the destination IP address is used, communication to an IP address not regis-
tered in Packet Filter settings is prohibited. Therefore, all destination IP addresses of the packets
that you want to allow must be set to the destination IP address in Packet Filter settings.
In addition, attention should be paid to the following.
• When you connect Sysmac Studio though Direct connection via Ethernet, set the Destination
IP Address to 169.254.0.0 and the Destination Mask to 255.255.0.0, and allow 169.254. ***.***.
Otherwise, the connection will fail.
5-28 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Case 3: Filtering by Source Port
You can filter access to the Controller by the source TCP/UDP port. This is useful when the source
TCP/UDP ports can be used to distinguish communications that are prohibited from communications
that are permitted. In Packet Filter’s source port settings, register TCP/UDP ports that are allowed to
communicate. Communications with unregistered TCP/UDP ports are prohibited.
 Application Example
An application example under the following conditions is shown below.
• Communications between the computer used in the facility and the Controller (source port: fixed
to TCP6000) are permitted, and communications with applications that are not permitted (source
port: other than TCP6000) are prohibited.
• An application running on the computer in the facility uses a socket communications program
and has a fixed source port.
The configuration of this application example is as follows. The socket communications program
that is allowed to communicate uses TCP port 6000.
Other application Socket communications Socket communications
TCP port No. other than 6000 TCP port No. 6000 TCP port No. 6000
Ethernet
Prohibited Permitted
NJ-series CPU Unit
Packet Filter settings are as follows: For Protocol, tcp is selected and 6000 for the source port.
No. Setting Set value
1 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol tcp
Source Port Specification Method Port specification
Range Specification No check.
Start Number 6000
End Number ---
Destination Port Specification Method any
Range Specification ---
Start Number ---
End Number ---
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-29
5-4
Packet
Filter
5
5-4-4
Case
Where
Packet
Filter
Is
Used
5 TCP/IP Functions
 Restrictions
If filtering by source port is used, communication from an unregistered TCP/UDP port is prohibited.
Therefore, the TCP/UDP ports of all devices communicating with the Controller must be set as the
source ports.
Omron's Support Software, such as Sysmac Studio, selects an unused port each time, so the user
cannot specify the source port. Therefore, the destination port must be set according to the proto-
cols used by the Omron’s Support Software. For details on the destination port settings, refer to
Case 4: Filtering by Destination Port on page 5-31.
If the Controller cannot communicate with a device that you want to allow, make sure that
TCP/UDP port used by the device is set correctly to the source port.
5-30 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Case 4: Filtering by Destination Port
You can filter access to the Controller by destination port in the packets received by the built-in Ether-
Net/IP port. Because the destination port is determined for each communication protocol, this function
is useful when the communication protocols used in the facility are fixed and you want to prohibit other
communications protocols. Register the destination port of allowed communications in Packet Filter
settings. Communications using unregistered destination ports are prohibited.
 Application Example
An application example under the following conditions is shown below.
• Communication protocols used in the facility are permitted, and the communication protocols not
used in the facility are prohibited.
• Access to the Controller from sources other than Sysmac Studio and OPC UA is prohibited in the
facility.
The configuration of this application example is as follows.
Sysmac Studio OPC UA FTP client
Prohibited
Ethernet
Permitted
Controller
NJ-series CPU Unit
Packet Filter settings are as follows. When Sysmac Studio version 1.50 or higher is connected, it
uses TCP port 443. OPC UA uses TCP port 4840.
Settings that allow Sysmac Studio to connect
No. Setting Set value
1 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol tcp
Source Port Specification Method any
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method Port specification
Range Specification No check.
Start Number 443
End Number ---
Settings that allow OPC UA to connect
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-31
5-4
Packet
Filter
5
5-4-4
Case
Where
Packet
Filter
Is
Used
5 TCP/IP Functions
No. Setting Set value
2 Source IP Address Specification Method any
IP Address ---
Mask ---
Destination IP Address Specification Method any
IP Address ---
Mask ---
Protocol tcp
Source Port Specification Method any
Range Specification ---
Start Number ---
End Number ---
Destination Port Specification Method Port specification
Range Specification No check.
Start Number 4840
End Number ---
 Restrictions
If filtering by destination port is used, communications to an unregistered destination port are pro-
hibited. Therefore, all destination ports used by the devices to communicate with must be regis-
tered to the destination port.
If the destination ports are not registered, the devices may time out.
If communication with a device that you want to allow fails, make sure that the destination port
used by the device is set correctly to the destination port of Packet Filter.
Additional Information
Selecting the Do not use Option for each communications protocol closes the TCP/UDP port
used for the communications protocol. This allows you to filter communications by destination
port in the same way as in Case 4.
5-32 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
5-4-5 Settings for Devices That Access the Controller
This section shows the set values of Packet Filter for each device that accesses the Controller.
Settings for Connecting Sysmac Studio
This section describes how to configure the destination port of Packet Filter when the Sysmac Studio
is connected.
The setting values for the destination port differ as shown below depending on the connection type
and setting on enabling connections to the Sysmac Studio and NA that are not supporting secure
communication.
Setting on ena- Destination port settings
bling connec-
tions to the Destination
Destination Destina- Destina-
Sysmac Studio Port
Connection type*1 Port tion Port tion Port
and NA that are Protocol Range
Specification Start End
not supporting Specifica-
Method Number Number
secure commu- tion
nication*2
Direct connection via Enable tcp Port specification No check. 80 ---
Ethernet*3 udp Port specification No check. 9600 ---
tcp*4 Port specification No check. 44818 ---
udp*4 Port specification No check. 44818 ---
icmp*4 --- --- --- ---
Disable tcp Port specification No check. 443 ---
udp Port specification No check. 9600 ---
Ethernet connection Enable tcp Port specification No check. 80 ---
via a hub tcp*4 Port specification No check. 44818 ---
icmp*4 --- --- --- ---
Disable tcp Port specification No check. 443 ---
Remote connection Enable tcp Port specification No check. 80 ---
via USB*5 tcp Port specification No check. 44818 ---
udp*6 Port specification No check. 44818 ---
Disable tcp Port specification No check. 443 ---
tcp Port specification No check. 44818 ---
udp*6 Port specification No check. 44818 ---
*1. For this setting, select Communications Setup from the Controller Menu, and select Connection type on
the Sysmac Studio.
*2. Set with the DIP switch. Refer to Troubleshooting When You Cannot Go Online from the Sysmac Studio in
the NJ/NX-series Troubleshooting Manual (Cat. No. W503) for details.
*3. For direct connection via Ethernet, the source and destination IP addresses must be set to 169.254. ***.***.
When filtering by IP address is used, set 169.254.0.0 to IP address and 255.255.0.0 to mask to allow this
address.
*4. This setting is required only when EtherNet/IP connection settings are made in the Sysmac Studio. This set-
ting is not required if no EtherNet/IP connection settings are made.
*5. For remote connection via USB, specify the IP address of the relayed Controller as the source IP address.
When filtering by IP address is used, allow this address.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-33
5-4
Packet
Filter
5
5-4-5
Settings
for
Devices
That
Access
the
Controller
5 TCP/IP Functions
*6. This packet is sent by local broadcast. Allow this address if filtering by destination IP address is enabled.
For example, if the Controller’s IP address is 192.168.250.1/24, specify 192.168.250.255 to the destination
IP address.
Additional Information
• To use the Ethernet Communications Test, which can be started by selecting Controller −
Communications Setup on the Sysmac Studio in the environment where Ethernet direct
connection is made, the following settings are required. Since this packet is sent by local
broadcast, allow this address when filtering by the destination IP address is used. For exam-
ple, if the Controller IP address is 192.168.250.1/24, specify 192.168.250.255 to the destina-
tion IP address.
Destination Port Destination Port Destination Port Destination Port
Protocol
Specification Method Range Specification Start Number End Number
udp Port specification No check. 9600 ---
• When the Use Option is selected for Packet Filter of the relayed Controller in the environment
where remote connection is made via USB, the following settings are required. In this case,
this packet has the connected Controller’s IP address as the source IP address and the re-
layed Controller’s IP address as the destination IP address. When filtering by IP address is
used, allow these addresses.
Destination Port Destination Port Destination Port Destination Port
Protocol
Specification Method Range Specification Start Number End Number
udp Port specification No check. 44818 ---
Settings for Connecting Support Software Other Than Sysmac Stu-
dio
The settings for connecting the Support Software other than Sysmac Studio are as follows.
Destination port settings
Destination Destination Destination Destination
Support Connection
Port Port Port Port
Software type Protocol
Specification Range Speci- Start Num- End Num-
Method fication ber ber
Network Either Ethernet tcp*1 Port specifica- No check. 44818 ---
Configura- I/F or NJ/NX/NY tion
tor for Series Ethernet udp*2 Port specifica- No check. 44818 ---
EtherNet/IP Direct I/F tion
icmp*1 --- --- --- ---
5-34 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Destination port settings
Destination Destination Destination Destination
Support Connection
Port Port Port Port
Software type Protocol
Specification Range Speci- Start Num- End Num-
Method fication ber ber
CX-Config- Either Ethernet Same settings as for Network Configurator.
uratorFDT I/F or NJ/NX/NY
Series Ethernet
Direct I/F
(Communication
DTM: OMRON
EtherNet/IP)
Any of Direct Same settings as for Sysmac Studio. Refer to Settings for Connecting Sysmac
connection via Studio on page 5-33 for settings for the Sysmac Studio.
Ethernet, The setting value differs depending on the version of CX-ConfiguratorFDT.
Ethernet For CX-ConfiguratorFDT version 2.57 or higher, set tcp: 443 for the destination
connection via port in Packet Filter settings.
a hub, or For CX-ConfiguratorFDT version 2.56 or lower, set tcp: 80 for the destination
Remote port in Packet Filter settings.
connection via
USB
(Communication
DTM: Nx built-in
EtherCAT or NX
CPU Unit Bus)
CX-Integra- Direct tcp Port specifica- No check. 9600 ---
tor, CX- connection via tion
Protocol Ethernet*3 udp Port specifica- No check. 9600 ---
(Network type: tion
Ethernet (FINS/
TCP))
Ethernet tcp Port specifica- No check. 9600 ---
connection via tion
a hub
(Network type:
Ethernet (FINS/
TCP))
Ethernet udp Port specifica- No check. 9600 ---
connection via tion
a hub
(Network type:
Ethernet)
CNC Oper- --- tcp any*4 --- --- ---
ator
icmp --- --- --- ---
SECS/GE --- tcp any*4 --- --- ---
M Configu-
icmp --- --- --- ---
rator
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-35
5-4
Packet
Filter
5
5-4-5
Settings
for
Devices
That
Access
the
Controller
5 TCP/IP Functions
Destination port settings
Destination Destination Destination Destination
Support Connection
Port Port Port Port
Software type Protocol
Specification Range Speci- Start Num- End Num-
Method fication ber ber
Sysmac Any of Direct Same settings as for Sysmac Studio. Refer to Settings for Connecting Sysmac
Conrtoller connection via Studio on page 5-33 for settings for the Sysmac Studio.
Log Upload Ethernet, The setting value differs depending on the version of Sysmac Studio that is in-
Tool Ethernet stalled.
connection via For Sysmac Studio version 1.50 or higher, allow tcp: 443 for the destination
a hub, or port.
Remote For Sysmac Studio version 1.49 or lower, allow tcp: 80 for the destination port.
connection via
USB
*1. For NJ/NX/NY Series Ethernet Direct I/F connection, specify 169.254.***.*** for the source IP address and
destination IP address. When filtering by IP address is used, set 169.254.0.0 to IP address and 255.255.0.0
to mask to allow this address.
*2. When filtering by IP address is used, allow the following IP addresses.
• NJ/NX/NY Series Ethernet Direct I/F: allow the following two addresses
a) Source IP address: Controller's IP address, Destination IP address: Local broadcast to the Control-
ler's network (When the Controller's IP address is 192.168.250.1/24, allow 192.168.250.255.)
b) Source IP address :169.254.***. ***, Destination IP address :169.254.***. *** (IP address 169.254.
***.*** is allowed by setting 169.254.0.0 to the IP address and 255.255.0.0 to the mask.)
• Ethernet I/F Connection
a) Source IP address: Computer's IP address, Destination IP address: Local broadcast to the comput-
er's network (When the computer's IP address is 192.168.250.100/24, allow 192.168.250.255.)
*3. For Direct connection via Ethernet, the source and destination IP addresses must be set to 169.254.
***.***. When filtering by IP address is used, set 169.254.0.0 to IP address and 255.255.0.0 to mask to allow
this address.
*4. This is selected to connect in FTP Passive Mode. Because the port used for data connection is not uniquely
determined, any must be selected for specification method.
Settings for Connecting a Programmable Terminal
The settings for connecting Programmable Terminals are as follows.
Destination port settings
Programmable Destination Port Destination Destination
Destination Port
Terminal Protocol Range Specifica- Port Port
Specification Method
tion Start Number End Number
NA-series tcp Port specification No check. 80 or 443*1 ---
NS-series tcp Port specification No check. 80 ---
tcp Port specification No check. 44818 ---
NB-series udp Port specification No check. 9600 ---
*1. For NA Runtime version 1.161 and NA5 system program version 10.0.0 or higher, set the destination port
start number to 443.
Settings for Each Communications Protocol
The settings for each communications protocol are as follows.
5-36 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
5 TCP/IP Functions
Destination port settings
Destination
Communications pro- Destination Port Destination Port Destination
Port
tocol Protocol Specification Meth- Range Specifica- Port
End Num-
od tion Start Number
ber
BOOTP client udp Port specification No check. 68 ---
DHCP client
OPC UA server tcp Port specification No check. 4840*1 ---
FINS/TCP server tcp Port specification No check. 9600*1 ---
FINS/UDP server udp Port specification No check. 9600*1 ---
SNMP agent udp Port specification Checked. 161*1 162*1
FTP server*2 tcp Port specification Checked. 20 21*1
In Active Mode
FTP server*2 tcp any*3 --- --- ---
In Passive Mode
TCP/UDP message udp Port specification No check. 64000*1 ---
service
tcp Port specification No check. 64000*1 ---
*1. If the port number has been changed, the new port number must be set.
*2. If the Controllers are FTP-clients, no Packet Filter settings are required.
*3. Because the port used for data connection is not uniquely determined, any must be selected for specifica-
tion method.
Settings for Using EtherNet/IP Communications
Make the following settings to use EtherNet/IP communications.
Destination port settings
Destination
Communi- Destination Destina- Destina-
Communica- Port cations Condition Port tion Port tion Port
tions Protocol Range
protocol Specification Start End
Specifica-
Method Number Number
tion
CIP messages UCMM Server tcp Port specifica- No check. 44818 ---
tion
icmp*1 --- --- --- ---
Class3 Server tcp Port specifica- No check. 44818 ---
tion
icmp*1 --- --- --- ---
Tag data links Class1 Originator igmp*2 --- --- --- ---
Target tcp Port specifica- No check. 44818 ---
tion
icmp*3 --- --- --- ---
CIP Safety Class0 Originator igmp*2 --- --- --- ---
communica-
Target tcp Port specifica- No check. 44818 ---
tions
tion
*1. Select this if CX-Compolet/SYSMAC Gateway is a client.
*2. Select this for Multicast.
*3. Select this when SYSMAC Gateway is the originator.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 5-37
5-4
Packet
Filter
5
5-4-5
Settings
for
Devices
That
Access
the
Controller
5 TCP/IP Functions
5-38 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6
Tag Data Link Functions
6-1 Introduction to Tag Data Links......................................................................6-2
6-1-1 Tag Data Links.................................................................................................6-2
6-1-2 Data Link Data Areas......................................................................................6-3
6-1-3 Tag Data Link Functions and Specifications....................................................6-6
6-1-4 Overview of Operation.....................................................................................6-7
6-1-5 Starting and Stopping Tag Data Links...........................................................6-10
6-1-6 Controller Status............................................................................................6-10
6-1-7 Concurrency of Tag Data Link Data..............................................................6-14
6-2 Setting Tag Data Links.................................................................................6-21
6-2-1 Starting the Network Configurator.................................................................6-21
6-2-2 Tag Data Link Setting Procedure...................................................................6-23
6-2-3 Registering Devices......................................................................................6-23
6-2-4 Creating Tags and Tag Sets..........................................................................6-25
6-2-5 Connection Settings......................................................................................6-38
6-2-6 Creating Connections Using the Wizard.......................................................6-48
6-2-7 Creating Connections by Dragging and Dropping Devices...........................6-52
6-2-8 Connecting the Network Configurator to the Network...................................6-54
6-2-9 Downloading Tag Data Link Parameters.......................................................6-62
6-2-10 Uploading Tag Data Link Parameters............................................................6-65
6-2-11 Verifying Tag Data Link Parameters..............................................................6-68
6-2-12 Starting and Stopping Tag Data Links...........................................................6-72
6-2-13 Clearing the Device Parameters...................................................................6-75
6-2-14 Saving the Network Configuration File..........................................................6-77
6-2-15 Reading a Network Configuration File...........................................................6-78
6-2-16 Checking Connections..................................................................................6-80
6-2-17 Changing Devices.........................................................................................6-81
6-2-18 Displaying Device Status...............................................................................6-83
6-3 Ladder Programming for Tag Data Links...................................................6-85
6-3-1 Ladder Programming for Tag Data Links.......................................................6-85
6-3-2 Status Flags Related to Tag Data Links........................................................6-89
6-4 Tag Data Links with Other Models..............................................................6-91
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-1
6
6 Tag Data Link Functions
6-1 Introduction to Tag Data Links
6-1-1 Tag Data Links
Tag data links enable cyclic tag data exchanges on an EtherNet/IP network between Controllers or be-
tween Controllers and other devices. Variables are assigned to tags. (You can also assign I/O memory
addresses to tags.)
The settings for tag data links are made with the Network Configurator. Refer to 6-2 Setting Tag Data
Links on page 6-21 for information on how to make the settings.
Additional Information
You can also use the Sysmac Studio to set the tag data links.
Refer to A-2 Use the Sysmac Studio to Set the Tag Data Links (EtherNet/IP Connections) on
page A-5 for details on setting the tag data links on the Sysmac Studio.
With a tag data link, one node requests the connection of a communications line to exchange data
with another node.
The node that requests the connection is called the originator, and the node that receives the request
is called the target.
NJ/NX-series CPU Unit EtherNet/IP Unit CJ-series CPU Unit
Input Output
Connection
Tag set name: ABC Tag set name: OUT1
Var_In_a I/O refreshing • Var_In_a • Var-Out1 Var-Out1(DM0)
Var_In_b • • V Va ar r_ _I In n_ _b c Input tags Output tags • • V Vaa rr -- OO uu tt 32 I/O refreshing Var-Out2(DM100)
Var_In_c Var-Out3(DM200)
Originator Target
Output Input DM00200
Var_Out_d Connection
Tag set name: XYZ Tag set name: IN1 WR300
VV aar r_ _O Ou ut t_ _e f I/O refreshing • • VV aa rr __O Ou ut t_ _ed Output tags Input tags • • D WM R0 30 02 000 I/O refreshing DM20100
• Var_Out_f • DM20100
Controller status
Controller status Target Originator
EEtthheerrNNeett//IIPP
For communications between Controllers, the connection information is set in the built-in EtherNet/IP
port of the Controller that receives (consumes) the data (i.e., the originator).
Additional Information
For communications between a Controller and an I/O device, the connection information is set
in the built-in EtherNet/IP port that is the originator. If an I/O device is used, the Network Config-
urator must have an EDS file installed that includes connection information for the I/O device.
Refer to A-3 EDS File Management on page A-42 for the installation procedure.
The output words and input words for each node for which data is exchanged must be set in the con-
nection information. These words are called an output tag set and an input tag set, respectively. Each
tag set must contain at least one tag.
6-2 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
The size of data for data exchange is the total size of tags included in the tag set. The size of the out-
put tag set and the size of the input tag set must match.
Precautions for Correct Use
• Select the Use Option for the CIP message server of the built-in EtherNet/IP port. If the Do
not use Option for the CIP message server is selected, tag data links cannot be performed.
For the details on the settings, refer to CIP Message Server on page 4-21.
• If the Use Option is selected for Packet Filter of the built-in EtherNet/IP port, make sure to
permit packets to be used for tag data links. If they are not permitted, tag data links are not
possible. For the details on the settings, refer to Packet Filter on page 4-8.
6-1-2 Data Link Data Areas
Tags
A tag is a unit that is used to exchange data with tag data links.
Data is exchanged between the local network variables and remote network variables specified in the
tags or between specified I/O memory areas.
Precautions for Correct Use
To maintain concurrency in the values of network variables that are assigned to tags, you must
set refreshing tasks.
Refer to 6-1-7 Concurrency of Tag Data Link Data on page 6-14 for details.
Tag Sets
When a data link connection is established, one or more tags (up to eight tags including Controller sta-
tus) are configured as a collective set of tags for the connection. This is called a tag set. Each tag set
represents a unit of data for one tag data link connection.
Tag data links are therefore created through a connection between one tag set and another tag set. A
tag set name must be set for each tag set.
NoteA connection is used to exchange data as a unit within which data concurrency is maintained.
Thus, data concurrency is maintained for all the data exchanged for one or more tags in one tag set.
Precautions for Correct Use
Data with tags is exchanged in the order that the tags are registered in the tag set. Register the
tags in the same order of the input and output tag sets.
 Example
In the following example, input tags "a" to "g" at the originator are a tag set named SP1_IN and
output tags "I" and "ii" are a tag set named SP1_OUT. A connection is set between these two tag
sets.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-3
6-1
Introduction
to
Tag
Data
Links
6
6-1-2
Data
Link
Data
Areas
6 Tag Data Link Functions
Originator device Target device
IP address: N
Connection Information
ž Target IP address: N
ž Originator tag set SP1_IN
ž Target tag set: SP1_OUT
ž Packet interval (RPI)
Tag set (input) Tag set (output)
Tag set name: SP1_IN Tag set name: SP1_OUT
Controller Status Controller Status
Tag i
Tag a
Connection
Tag ii
Tag b
Tag c
:
Tag g
EtherNet/IP
There are input (consume) and output (produce) tag sets. Each tag set can contain either input
tags or output tags. The same input tag cannot be included in more than one input tag set.
 Number of Tags in Tag Sets
You can set one or more tags for each of the input and output tag sets for one connection.
For example, you can set the input tag set with one tag, and the output tag set with more than one
tag.
• Tag Set with Only One Tag Each
With basic Network Configurator procedures, each tag set contains only one tag.
6-4 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
NJ/NX-series CPU Unit CJ-series CPU Unit
I/O memory
Tag set SP1_IN Tag set SP1_OUT
(tag a) (tag c)
Connection
Variable a Variable c
Individual tags
Tag set SP2_OUT Tag set SP2_IN
(tag b) (tag d)
Connection
Variable b Variable d
EtherNet/IP
• Tag Sets Each with Multiple Tags
For NX701 CPU Units, you can assign up to eight tags (up to 722 words in total) in one tag set.
For NX502 CPU Units, you can assign up to 64 tags (up to 722 words in total) in one tag set.
For NX102 CPU Units, NX1P2 CPU Units, and NJ-series CPU Units, you can assign up to eight
tags (up to 300 words in total) in one tag set.
NJ/NX-series CPU Unit CJ-series CPU Unit
I/O memory
Tag set SP1_IN
(group of tags a, b, and c)
Tag set SP1_OUT
Variable a Variable f
Connection
Variable b Variable g
Variable c Variable h Individual tags
Tag set SP2_OUT
Tag set SP2_IN
(group of tags d and e)
Variable d Connection Variable i
Variable e Variable j
EtherNet/IP
NoteTo enable a connection, each tag set must include only one of ether input tags or output tags. (Both in-
put and output tags cannot be included in one tag set.)
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-5
6-1
Introduction
to
Tag
Data
Links
6
6-1-2
Data
Link
Data
Areas
6 Tag Data Link Functions
6-1-3 Tag Data Link Functions and Specifications
The tag data link and performance specifications of the NJ/NX-series CPU Unit are given below.
Specification
NJ501-££££/NJ301-£
£££/NJ101-££££
Item NX701-££ NX502-££ NX102-££ NX1P2-££
Unit ver- Unit ver-
££ ££ ££ £££££
sion 1.00 sion 1.03
to 1.02 or later
Communications type Standard EtherNet/IP implicit communications (connection-type cyclic communica-
tions)
Setting method After you have set tags, tag sets, and connections with the Network Configurator,
you must download tag data link parameters to all devices on the EtherNet/IP net-
work. After the parameters are downloaded, the EtherNet/IP Units are restarted to
start the tag data links.
You can export network variables that you created on the Sysmac Studio to a CSV
file.
You can then import the file to the Network Configurator and assign the network
variables to the tags.
Tags Supported variable You can specify the following network variables as tags. *2, *3
*1 types • Global variables
Maximum number 722 words (1,444 bytes) 300 words (600 bytes)
of words per tag
Maximum number 256 256*4
of tags (total of 512 with two ports)
Tag Maximum number 8 (7 when 64 (63 8 (7 when Controller status is included)
sets of tags per tag set Controller when Con-
status is in- troller sta-
cluded) tus is in-
cluded)
Maximum number 722 words (1,444 bytes) 300 words (600 bytes)
of words per tag
set
Maximum number 256 (total of 64 (total of 32 (total of 32
of tag sets 512 with 128 with 40 with two
two ports) two ports) ports)*5
Connection Maximum Maximum Maximum Maximum number of connections per
number of number of number of Unit: 32
connections connections connections
per Unit: per Unit: per Unit: 64
512 (256 128 (64 per (32 per
per port) port) port)
Connection type Each connection can be set for 1-to-1 (unicast) or 1-to-N (multicast) communica-
tions.
Packet intervals (RPI) 0.5 to 1 to 10,000 ms in 1-ms in- 2 to 10,000 10 to 1 to 10,000
10,000 ms crements ms in 1-ms 10,000 ms ms in 1-ms
in 0.5-ms increments in 1-ms in- increments
increments crements
The packet interval can be set separately for each connection.
6-6 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
Specification
NJ501-££££/NJ301-£
£££/NJ101-££££
Item NX701-££ NX502-££ NX102-££ NX1P2-££
Unit ver- Unit ver-
££ ££ ££ £££££
sion 1.00 sion 1.03
to 1.02 or later
Allowed communications 40,000 20,000 12,000 pps 3,000 pps 1,000 pps 3,000 pps
bandwidth per Unit (pps) pps*6 pps*6 *6
Note: The Note: The Note: The Note: The heartbeat is included.
heartbeat is heartbeat heartbeat
included. and the CIP and the CIP
Safety rout- Safety rout-
ing are in- ing are in-
cluded. *7 cluded. *8
*1. When you specify a specific I/O memory address for a tag for an NX502 CPU Unit, NX102 CPU Unit,
NX1P2 CPU Unit, or NJ-series CPU Unit, create a variable with an AT specification for the I/O memory ad-
dress on the Sysmac Studio, and then specify the variable with the AT specification for the tag. For NX502
CPU Units, NX102 CPU Units, and NX1P2 CPU Units, you need to set memory used for CJ-series Unit to
use the I/O memory address.
For details on memory settings used for CJ-series Unit, refer to the NJ/NX-series CPU Unit Software User's
Manual (Cat. No. W501).
*2. You can import network variables created in the Sysmac Studio to the Network Configurator as tags.
If variables for which Network publish attribute is set on the Sysmac Studio contain I/O memory addresses,
such as "0000" and "H0000", they are not exported to CSV files.
*3. The following table lists variables that you can specify as tags.
Data types Example Specification
Variables with basic data types aaa Supported
Enumerated variables bbb Supported
Array variables Arrays ccc Supported
Elements ccc[2] Supported
Structure variables Structures ddd Supported
Members ddd.xxx Supported
Union variables Unions eee Supported
Members eee.yyy Supported
*4. The maximum number of tags is given for the following conditions.
• All tag sets contain eight tags.
• The maximum number of tag sets (32) is registered.
*5. If more than 40 tag sets are set in total, a Number of Tag Sets for Tag Data Links Exceeded (840E0000 hex)
event occurs.
*6. If the two built-in EtherNet/IP ports are used simultaneously, the maximum communications data size means
the maximum data size of the total of the two ports.
*7. An NX502 CPU Unit with unit version 1.64 or later is required to use the CIP Safety routing.
*8. An NX102 CPU Unit with unit version 1.31 or later is required to use the CIP Safety routing.
6-1-4 Overview of Operation
In this manual, the connection information that is set is called tag data link parameters.
This section describes how to set tag data links with the Sysmac Studio and the Network Configurator.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-7
6-1
Introduction
to
Tag
Data
Links
6
6-1-4
Overview
of
Operation
6 Tag Data Link Functions
Setting Network Variables (Sysmac Studio)
First, create any variables that you want to use for tag data links as network variables on the Sysmac
Studio.
1
Set the Network Publish attribute to Input or Output in the Global Variable Table for variables
you want to use for tag data links (i.e., as tags).
2
To maintain concurrency in tag data within a tag set, set all tags (i.e., variables with a Network
Publish attribute) within the same tag set as follows:
Set a refreshing task for variables with a Network Publish attribute to maintain concurrency for
tag data link data as described below.
• Maintain concurrency in the tag data in a tag set.
• The timing of updating network variables that are assigned to tags is synchronized with the
execution period of a program that accesses the network variables.
Refer to 6-1-7 Concurrency of Tag Data Link Data on page 6-14 for details on the concurren-
cy of tag data link data.
Precautions for Correct Use
• If a variable with an AT specification is used as a tag, you do not need to set a refreshing
task.
It is refreshed in the primary periodic task.
• You cannot use the following notation, which specifies an I/O memory address, in the variable
name of any variable used in a tag data link.
a) Variable names that contain only single-byte numerals (Example: 001)
b) Variable names with the following single-byte letters (uppercase or lowercase) followed by
single-byte numerals
1) H (Example: H30)
2) W (Example: w30)
3) D (Example: D100)
4) E0_ to E18_
• When the server function of CIP message communications is disabled, the tag data links can-
not be used. Enable the server function of CIP message communications. Refer to CIP Mes-
sage Server on page 4-21 for details on setting CIP message server.
Setting and Downloading Tag Data Link Parameters (Network Con-
figurator or Sysmac Studio)
The following tag data link parameters (e.g., connection information) are created with the Network
Configurator or the Sysmac Studio, and then the parameters are downloaded to all originator devices
on the EtherNet/IP network.
6-8 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
When the tag data links are used on built-in EtherNet/IP ports, use the Network Configurator to make
the following settings.
Additional Information
In the settings of the following tag data link parameters, the specifications of the settable num-
bers and the ranges differ depending on the CPU Unit or the version of the CPU Unit. For de-
tails, refer to 1-3-1 Specifications on page 1-9.
1
Creating the Configuration Information
Register EtherNet/IP ports and EtherNet/IP Units to create connections that define the tag data
links. For details, refer to 6-2-3 Registering Devices on page 6-23.
2
Setting Tags
Create CPU Unit variables for input (consume) tags and output (produce) tags.
You can import and export network variables that are created on the Sysmac Studio to CSV
files. This allows you to register them as tags on the Network Configurator.
Output (produce) tags can be defined to clear output data to 0 or to hold the output data from
before the error when a fatal error occurs in the CPU Unit.
3
Setting Tag Sets
Create output tag sets and input tag sets and assign tags to them. (You can create up to eight
I/O tag sets.) You can specify the Controller status that indicates the CPU Unit's operating sta-
tus (operating information and error information) in a tag set.
4
Setting connections
Link the output tag sets for the target device and the input tag sets for the originator device as
connections.
 Connection Setting Parameters
The connection settings in step 4 above have the following setting parameters.
• Setting the Requested Packet Interval (RPI)
The RPI (Requested Packet Interval) is the I/O data refresh cycle on the Ethernet line when tag
data links are established. With EtherNet/IP, data is exchanged on the communications line at
the RPI that is set for each connection, regardless of the number of nodes.
With the built-in EtherNet/IP port, you can set RPI for each connection.
• Setting Multi-cast or Unicast Communications
You can select a multicast connection or unicast (point-to-point) connection as the connection
type in the tag data link connection settings.
With a multicast connection, you can send an output tag set in one packet to multiple nodes and
make allocations to the input tag sets.
A unicast connection separately sends one output tag set to each node, and so it sends the
same number of packets as the number of input tag sets.
Therefore, multicast connections can decrease the communications load if one output tag set is
sent to multiple nodes.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-9
6-1
Introduction
to
Tag
Data
Links
6
6-1-4
Overview
of
Operation
6 Tag Data Link Functions
To use a multicast connection and send an output tag set in one packet to multiple nodes, the
following settings for the receiving node must be the same as the settings of the sending node:
the connection type (multicast), the connection I/O type, packet internal (RPI), and timeout value.
Precautions for Correct Use
• The performance of communications devices is limited to some extent by the limitations of
each product's specifications. Consequently, there are limits to the packet interval (RPI) set-
tings.
Refer to 14-2 Adjusting the Communications Load on page 14-7Checking the Device Band-
width Usage on page A-25 and set an appropriate packet interval (RPI).
• If multicast connections are used, however, use an Ethernet switch that has multicast filtering,
unless packets are received by all nodes in the network.
If an Ethernet switch without multicast filtering is used, multicast packets are broadcast to the
entire network, and so the packets are sent to nodes that do not require them, which will
cause the communications load on those nodes to increase.
• If you use data tag links with multicast traffic at a baud rate over 100 Mbps, use an Ethernet
switch that supports a baud rate of 1000 Mbps.
If there is an Ethernet device on the same network that communicates at 100 Mbps or less,
the device may affect tag data link communications and cause tag data links to be broken,
even if the device is not related to tag data link communications.
Additional Information
• To calculate the number of connections of each connection type, refer to 14-1-2 Calculating
the Number of Connections on page 14-4.
• If the maximum number of connections is exceeded, you must review the number of connec-
tions for the built-in EtherNet/IP port, or the number of nodes. When you use an NJ-series
CPU Unit, you can also consider adding EtherNet/IP Units.
6-1-5 Starting and Stopping Tag Data Links
Tag data links are automatically started when the data link parameters are downloaded from the Net-
work Configurator and the power supply to the NJ/NX-series Controller is turned ON.
Thereafter, you can start and stop tag data links for the entire network or individual devices from the
Network Configurator. Starting and stopping tag data links for individual devices must be performed for
the originator.
Furthermore, you can use system-defined variables to start and stop the entire network. Refer to
6-2-12 Starting and Stopping Tag Data Links on page 6-72 for details.
6-1-6 Controller Status
You can include the Controller status as a member of a tag set in the data sent and received.
The Controller status is a set of flags that indicate the operating status of the CPU Unit (operating in-
formation, error information, Controller error level).
If the Controller status is specified as an output (produce) tag, the Controller status is added to the
start of the tag set in the following format.
(Select the Include Option for Controller Status in the upper right of the Edit Tag Set Dialog Box.)
6-10 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 0 0 0 0 0 0 0 0 0 0
Controller Operating Flag
Minor fault level
Controller error
Controller Error Flag
Partial fault level Controller error
Major fault level
Controller error
NoteOf the flags in bits 5 to 7 that indicate the current error level, only the flag for the highest error level changes
to TRUE.
For example, if a minor fault level Controller error and a major fault level Controller error occur at the same
time, only the flag for the major fault level Controller error (bit 7) will change to TRUE and the flag for the
minor fault level Controller error (bit 5) will remain as FALSE.
To receive the Controller status, specify the Controller status for the In - Consume Tab Page in the
dialog box used to edit the receive tag set.
(Select the Include Option for Controller Status in the upper right of the Edit Tag Set Dialog Box.)
When a tag data link is started, the contents of the Controller status is stored in the system variables
that are given below.
• Target PLC Operating Mode
NX701 CPU Unit: _EIP1_TargetPLCModeSta (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCModeSta (for the built-in EtherNet/IP port 2)
NX102 CPU Unit: _EIP1_TargetPLCModeSta (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCModeSta (for the built-in EtherNet/IP port 2)
NX502 CPU Unit: _EIP1_TargetPLCModeSta (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCModeSta (for the built-in EtherNet/IP port 2)
NX1P2 CPU Unit: _EIP1_TargetPLCModeSta (for the built-in EtherNet/IP port 1)
NJ-series CPU Unit _EIP_TargetPLCModeSta
• Target PLC Error Information
NX701 CPU Unit: _EIP1_TargetPLCErr (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCErr (for the built-in EtherNet/IP port 2)
NX102 CPU Unit: _EIP1_TargetPLCErr (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCErr (for the built-in EtherNet/IP port 2)
NX502 CPU Unit: _EIP1_TargetPLCErr (for the built-in EtherNet/IP port 1)
_EIP2_TargetPLCErr (for the built-in EtherNet/IP port 2)
NX1P2 CPU Unit: _EIP1_TargetPLCErr (for the built-in EtherNet/IP port 1)
NJ-series CPU Unit: _EIP_TargetPLCErr
Example: Using an NJ-series CPU Unit to send the Target PLC Operating Mode of the Target Node
with an IP Address of 192.168.250.2
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-11
6-1
Introduction
to
Tag
Data
Links
6
6-1-6
Controller
Status
6 Tag Data Link Functions
IP address = 192.168.250.2
_EIP_TargetPLCModeSta (Target PLC Operating Mode)
0
Value of last byte = 2 1
2
Target node ID = #002
254
255
NJ-series Controller CJ-series CPU Unit
Controller status
Controller status (when included) Controller status (when included)
Controller Status
I/O memory
Output tag set Input tag set
Variable a Variable f
Connection
Variable b Variable g
Variable c Variable h
Target data link status
EtherNet/IP
Additional Information
The target node ID may be duplicated depending on the IP address of the target node. In this
case, it is necessary to change the target node ID on the Network Configurator so that the
same address could not be used by more than one node.
For information on how to change the target node ID, refer to Step 4 under Registering Devices
in the Register Device List in Connection Settings in 6-2-5 Connection Settings on page 6-38.
When you use multiple connections to communicate with one specific node, the information of the
Controller status is stored in the following variables if the Controller status is specified in the input tags
and the output tags for all the connections.
6-12 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
Controller sta-
Variable name Description of operation
tus
Controller Oper- Target PLC Operating Mode This flag shows the operation information of the
ating Flag • NX701 CPU Unit Controller at the target node.
_EIP1_TargetPLCModeSta (for (When the Built-in EtherNet/IP Port Is the Originator
the built-in EtherNet/IP port 1), or of the Connection)
_EIP2_TargetPLCModeSta (for The array element that corresponds to the target
the built-in EtherNet/IP port 2) node ID at the target is set to TRUE when all infor-
• NX102 CPU Unit mation for all the connections to the relevant target
_EIP1_TargetPLCModeSta (for node shows operating status.
the built-in EtherNet/IP port 1), or You can change the target node ID for the IP ad-
_EIP2_TargetPLCModeSta (for dress from the Network Configurator.
the built-in EtherNet/IP port 2) This status information is enabled when the Control-
• NX502 CPU Unit ler status is included in the communications data for
_EIP1_TargetPLCModeSta (for both the originator and the target node.
the built-in EtherNet/IP port 1), or This variable is updated when necessary.
_EIP2_TargetPLCModeSta (for
the built-in EtherNet/IP port 2)
• NX1P2 CPU Unit
_EIP1_TargetPLCModeSta (for
the built-in EtherNet/IP port 1)
• NJ-series CPU Unit
_EIP_TargetPLCModeSta
Controller Error Target PLC Error Information This variable shows the error status (logical OR of
Flag • NX701 CPU Unit fatal and non-fatal errors) of the target node Control-
_EIP1_TargetPLCErr (for the built- lers.
in EtherNet/IP port 1), or (When the Built-in EtherNet/IP Port Is the Originator
_EIP2_TargetPLCErr (for the built- of the Connection)
in EtherNet/IP port 2) You can change the target node ID for the IP ad-
• NX102 CPU Unit dress from the Network Configurator.
_EIP1_TargetPLCErr (for the built- The Controller Error Flags are enabled when the
in EtherNet/IP port 1), or Controller status is included in the communications
_EIP2_TargetPLCErr (for the built- data for both the originator and target node.
in EtherNet/IP port 2) This variable is updated when necessary.
• NX502 CPU Unit
_EIP1_TargetPLCErr (for the built-
in EtherNet/IP port 1), or
_EIP2_TargetPLCErr (for the built-
in EtherNet/IP port 2)
• NX1P2 CPU Unit
_EIP1_TargetPLCErr (for the built-
in EtherNet/IP port 1)
• NJ-series CPU Unit
_EIP_TargetPLCErr
Additional Information
Even if you specify including the Controller status in output (produce) tags, you do not necessa-
rily need to include the Controller status in input (consume) tags.
If you do not include the Controller status in an input (consume) tag, the contents of the Control-
ler status are not updated in the Target PLC Operating Mode and Target PLC Error Information
variables, but they are sent in the input (consume) tag.
Therefore, you can use the Controller status data that was received in the input (consume) tag
as receive data.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-13
6-1
Introduction
to
Tag
Data
Links
6
6-1-6
Controller
Status
6 Tag Data Link Functions
6-1-7 Concurrency of Tag Data Link Data
To maintain the concurrency of data in a tag data link, you must set a refreshing task for each network
variable that is assigned to a tag.
• Maintain concurrency in tag data in a tag set.
• The timing of updating network variables that are assigned to tags is synchronized with the execu-
tion period of the program that accesses the network variables
Additional Information
A refreshing task maintains concurrency of the value of a global variable from all tasks that ac-
cess that global variable. This is achieved by specifying a single task that can write to that glob-
al variable and not allowing any other task to write to that global variable.
For details on refreshing tasks, refer to the NJ/NX-series CPU Unit Software User's Manual
(Cat. No. W501).
Maintaining Concurrency in the Tag Data in a Tag Set
To maintain concurrency in the values of multiple tags in a tag set, the tags (variables with a Network
Publish attribute) must satisfy all of the following conditions.
a. The tags must be assigned to the same tag set (connection).
b. A refreshing task must be set for network variables assigned to the tags, and the refreshing task
must be the same for all the tags in the tag set. *1
c. For NX502, NX102, NX1P2, and NJ-series CPU Units, a tag with an AT specification must not be
included in the tag set.
d. The variable access time set for each task must be set to a higher value than is required to transfer
the tag data.
Refer to 14-3-3 Relationship between Task Periods and Packet Intervals (RPIs) on page 14-26 for
details on the variable access time and data transfer.
*1. If you set a refreshing task for network variables, you must set a variable access time to allocate enough time
to access the network variables from outside of the Controller.
• Setting Refreshing Tasks for Tags (Network Variables)
Concurrency of the tags in the tag set is maintained.
6-14 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
NJ/NX-series Controller NJ/NX-series Controller
Refreshing task Refreshing task
Value of variable Tag set Tag set Value of variable
Variable a 100"10 Variable a Connection Variable d 10
The values of the
Variable b 100"10 Variable b Tag data links updated. Variable e 10 tags in the tag set
are refreshed at
Variable c 100"10 Variable c Variable f 10 the same time.
EtherNet/IP
Additional Information
For NX502, NX102, NX1P2, and NJ-series CPU Units, you do not need to set a refreshing task
for variables (tags) with AT specifications since they are updated in the primary periodic task.
• Not Setting Refreshing Tasks for Tags (Network Variables)
Concurrency of the tags in the tag set is not maintained.
NJ/NX-series Controller NJ/NX-series Controller
Refreshing task Refreshing task
Value of variable Tag set Tag set Value of variable
The
values of
Variable a 100 → 10 Variable a Connection Variable d 10 Refreshed. tags in
the tag
Variable b 100 → 10 Variable b Tag data links updated. Variable e 10 Refreshed. set are
not
refreshed
Variable c 100 → 10 Variable c Variable f 100 Not refreshed. at the
same
time.
EtherNet/IP
Synchronizing the Update Timing of Network Variables (Tags) with
the User Program Execution Period
To have the values of network variables (tags) updated to the latest tag data values each time the user
program that accesses those network variables is executed, set the refreshing task for the network
variables (tags) to the same type of the task as for the user program that accesses the network varia-
bles (tags).
The difference between the operation of tags with a refreshing task that is the same as the user pro-
gram and tags without a refreshing task is described below.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-15
6-1
Introduction
to
Tag
Data
Links
6
6-1-7
Concurrency
of
Tag
Data
Link
Data
6 Tag Data Link Functions
• Tag (network variable) with a refreshing task
The tag is refreshed each time the program with the task that is set as the refreshing task is execut-
ed.
• Tag (network variable) without a refreshing task
The tag (network variable) is refreshed in the following processing. Refreshing is not synchronized
with the execution timing of the program.
a) NJ-series Controller, NX102, and NX1P2 CPU Units: System service
b) NX701 CPU and NX502 CPU Units: Tag data link variable access service
The following figures show the refreshing timing of network variables for the respective CPU Units.
NX701 CPU Unit
• The tag data link service and tag data link variable access service are executed without being affect-
ed by the task and system services.
• The system services are executed at the required time without being affected by the task, tag data
link service, and tag data link variable access service.
(1) Execution timing of the program
(2) Refresh timing of network variables (tags) with the primary periodic task set as the refreshing task*
(3) Refresh timing of network variables (tags) that do not have the primary periodic task set as the refreshing task
(1) (2) (1) (2) (1) (2) (1) (2) (1) (2)
Primary period
Execution
priority
High
IOUPG MC IOUPG MC IOUPG MC IOUPGMC IOUPG MC
Primary
periodic task
Task period
Priority-16 IOUPG (2) IO UPG
periodic task
Tag data link
service
(3)
Tag data is read
Tag data link
from the tag set.
variable
access service
Task period
Priority-17
UPG Pausing
periodic task
Low
*: Refreshed during system common processing 2 in the task processing.
NX502 CPU Unit
• Communications bridge service, tag data link service, tag data link refresh service for X Bus Units,
tag data link variable access service, and system services can be executed in parallel with task exe-
cution.
• The order of execution priority is in the following order; communications bridge service, tag data link
service, tag data link refresh service for X Bus Units, tag data link variable access service. The sys-
tem services are executed without being affected by the communications bridge service, tag data
link service, tag data link refresh service for X Bus Units, and tag data link variable access service.
6-16 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
(1) Execution timing of the program
(2) Refresh timing of network variables (tags) with the primary periodic task set as the refreshing task*
(3) Refresh timing of network variables (tags) that do not have the primary periodic task set as the refreshing task
(1) (2) (1) (2) (1) (2) (1) (2) (1) (2)
Execution
Primary period
priority
High
Primary IO UPGMC IO UPGMC IO UPGMC IO UPGMC IO UPGMC
periodic task
Execution interval of the communucations bridge service
Communications
bridge service
Execution time
of the communucations bridge service
(2)
Tag data link
service
Execution time of the tag data link service
Tag data is read
from the tag set.
Tag data link
refresh service
for X Bus Units
Execution time of the tag data link refresh
service for X Bus Units
(3)
Tag data link
variable
access service
Execution time of the tag data link variable
access service
Task period
Priority-17 UPG Pausing
periodic task
Low
*: Refreshed during system common processing 2 in the task processing.
Version Information
• The communications bridge service is executed for an NX502 CPU Unit with unit version 1.64
or later.
• The tag data link refresh service for X Bus Units is executed when the NX502 CPU Unit with
unit version 1.66 or later and the NX-series EtherNet/IP Unit with unit version 1.01 or later are
used together.
NX102 CPU Units
• The communications bridge service, tag data link service and system service can be executed in
parallel with the tasks.
• The execution priority is higher in the order of communications bridge service, tag data link service
and then system service.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-17
6-1
Introduction
to
Tag
Data
Links
6
6-1-7
Concurrency
of
Tag
Data
Link
Data
6 Tag Data Link Functions
(1) Execution timing of the program
(2) Refresh timing of network variables (tags) with the primary periodic task set as the refreshing task*
(3) Refresh timing of network variables (tags) that do not have the primary periodic task set as the refreshing task
(1) (2) (1) (2) (1) (2) (1) (2) (1) (2)
Execution
Primary period
priority
High
Primary IO UPGMC IO UPGMC IO UPGMC IO UPGMC IO UPGMC
periodic task
Execution interval of the communucations bridge service
Communications
bridge service
(2)
Execution time
of the communucations bridge service
Tag data link
service
Tag data is read Execution time of the tag data link service
from the tag set.
(3)
Task period
Priority-17
periodic task UPG Pausing
System
services
Low
(3)
*: Refreshed during system common processing 2 in the task processing.
Version Information
The communications bridge service is executed by the NX102 CPU Unit with unit version 1.31
or later.
NX1P2 CPU Unit
• The tag data link service, option board service, and system services can be executed in parallel with
the the execution of tasks.
• The order of execution priority is tag data link service, option board service and then system serv-
ices.
6-18 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
(1) Execution timing of the program
(2) Refresh timing of network variables (tags) with the primary periodic task set as the refreshing task*
(3) Refresh timing of network variables (tags) that do not have the primary periodic task set as the refreshing task
(1) (2) (1) (2) (1) (2) (1) (2) (1) (2)
Primary period
Execution
priority
High Primary IOUPGMC IOUPGMC IOUPGMC IOUPGMC IOUPGMC
periodic task
Tag data link service execution interval
(2)
Tag data link
service
(3)
Tag data is read
Option board from the tag set.
service
Task period
Priority-17
UPG Pausing
periodic task
System service
(3)
Low *: Refreshed during system common processing 2 in the task processing.
NJ-series CPU Units
• Execution of the tag data link service is given priority over execution of the priority-17 periodic task.
However, execution of the primary periodic task and priority-16 periodic task is given even higher
priority.
• System services are executed in unused time between execution of all of the tasks and tag data link
service.
(1) Execution timing of the program
(2) Refresh timing of network variables (tags) with the primary periodic task set as the refreshing task*
(3) Refresh timing of network variables (tags) that do not have the primary periodic task set as the refreshing task
(1) (2) (1) (2) (1) (2) (1) (2) (1) (2)
Executio n
priority Primary period
High IOUPG MC IOUPG MC IOUPG MC IOUPGMC IOUPG MC
Primary
periodic task
Task period
Priority-16 IOUPG IO UPG
periodic task (2)
(3)
Tag data link
service
Task period
Priority-17 Tag data is read UPG Pausing
periodic task from the tag set. (3)
.....The system service is executed
System service
during free time between task
execution.
Low *: Refreshed during system common processing 2 in the task processing.
Additional Information
If a user program needs to access a network variable with an AT specification, set the program
in the primary periodic task so that it matches the refresh timing of the network variable with the
AT specification. (This applies to NX502, NX102, NX1P2, and NJ-series CPU Units.)
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-19
6-1
Introduction
to
Tag
Data
Links
6
6-1-7
Concurrency
of
Tag
Data
Link
Data
6 Tag Data Link Functions
Additional Information
Relationship between Refreshing Tasks and Data Concurrency in Tag Data Links
If you do not specify a refreshing task for global variables in tag data links, the following may
occur.


Question: When data is sent for the output tag set, another task may have already written different val-

Answer: ues before that data is sent, depending on the timing of the task.


Question: When data is received by an input tag set, another task may write different values after that

Answer:
data is received, depending on the timing of the task.
Therefore, to maintain concurrency of data in tag data links, you must specify the same re-
freshing task on both the output CPU Unit and the input CPU Unit.
NJ/NX-series CPU Unit NJ/NX-series CPU Unit
Refreshing Refreshing
task task
This variable may Tag set Tag set
already be written This variable
by another task Variable a Connection Variable d may be written
before you send by another task
the data. after you receive
Variable b Tag data links Variable e the data.
updated.
Variable c Variable f
EtherNet/IP
Data concurrency is not maintained
unless you assign the same
refreshing task for both the output
and the input tags.
Required Processing Time to Maintain Concurrency
When you set a refreshing task for tags (network variables) to maintain the concurrency of data link
data, the processing time required for that specified task increases. Due to this increase in task proc-
essing time, tag data link data may not be refreshed at the packet interval (RPI) period set for each
connection.
Therefore, you need to adjust the packet interval (RPI) settings to match the period of the task speci-
fied as the refreshing task.
Refer to 14-3-3 Relationship between Task Periods and Packet Intervals (RPIs) on page 14-26 for de-
tails.
Task Setup Procedure


Question: Set the global variables for which to specify a refreshing task, and set the refreshing tasks and ac-

Answer:
cessing tasks in the Settings for Exclusive Control of Variables in Tasks in the Task Setup Tab
Page on the Sysmac Studio.


Question: Set the variable access time for each refreshing task.

Answer:
For details, refer to NJ/NX-series CPU Unit Software User's Manual (Cat. No. W501).
6-20 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
6-2 Setting Tag Data Links
Additional Information
You can also use the Sysmac Studio to set the tag data links.
Refer to A-2 Use the Sysmac Studio to Set the Tag Data Links (EtherNet/IP Connections) on
page A-5 for details on setting the tag data links on the Sysmac Studio.
6-2-1 Starting the Network Configurator
Procedure
Tag data links are set from the Network Configurator. Use the following procedure to start the Network
Configurator.
 Using the Windows Start Menu
To start the Network Configurator, select OMRON – Sysmac Studio – Network Configurator for
EtherNetIP – Network Configurator.
When the Network Configurator starts, the following window is displayed.
Main Window
The Main Window consists of a Hardware List and a Network Configuration Pane, as shown in the
following diagram.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-21
6-2
Setting
Tag
Data
Links
6
6-2-1
Starting
the
Network
Configurator
6 Tag Data Link Functions
To manage two or more networks, you can select Network – Add. You can add a new Network Con-
figuration Pane.
To change the network name displayed in the Network Tab Page, select Network – Property. You can
change the network name as set in the Comment Field of the Network Property Dialog Box.
6-22 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
6-2-2 Tag Data Link Setting Procedure
This section describes the procedure to set tag data links (i.e., connection information).
For data links between Controllers, the connection information is set only in the originator, i.e., the
node that receives data.
1 Create the network configuration.


Question: Register all the built-in EtherNet/IP ports for which to create connections, in the EtherNet/IP Net-

Answer:
work Configuration Pane. (Refer to 6-2-3 Registering Devices on page 6-23)
NoteIf a system has already been installed, connect online to the EtherNet/IP network and up-
load the network configuration. (Refer to 6-2-10 Uploading Tag Data Link Parameters on
page 6-65)
↓
2 Create the tag and tag set connections.


Question: Create tags and tag sets for all the registered devices (built-in EtherNet/IP ports). (Refer to

Answer: 6-2-4 Creating Tags and Tag Sets on page 6-25)


Question: Create a connection for the originator device (i.e., the registered device that receives data as in-

Answer:
put data). (Refer to 6-2-5 Connection Settings on page 6-38)
↓
3 Download the tag data link parameters. (Refer to 6-2-9 Downloading Tag Data Link Parameters
on page 6-62)
↓
4 Make sure that the tag data links are operating normally, by using the indicators for the built-
in EtherNet/IP port (refer to the NJ/NX-series Troubleshooting Manual (Cat. No. W503)) and the
device monitor function of the Network Configurator (refer to 15-2 Checking Status with the
Network Configurator on page 15-3).
↓
5 Make sure that the output tag data is reflected in the input tags by checking the Watch Tab
Page on the Sysmac Studio.
Refer to the Sysmac Studio Version 1 Operation Manual (Cat. No. W504) for the procedure.
Additional Information
If the tag data links are performed with a device that do not have EDS files, use the Generic
Device to make the settings.
Refer to A-9 Tag Data Link Settings with Generic Devices on page A-67 for information on how
to make the settings with the Generic Device.
6-2-3 Registering Devices
Register all of the devices required in the equipment (such as EtherNet/IP Units performing tag data
links) in the network configuration.
1
Register the devices that will participate in the tag data links by dragging the devices from the
Hardware List and dropping them in the Network Configuration Pane on the right. (To drag and
drop an icon, click and hold the left mouse button over the icon, move the icon to the destina-
tion, and release the mouse button.)
You can also select a device in the Hardware List and press the Enter Key to register it. The
icon of the device is displayed in the Network Configuration Pane, as shown in the following
picture.
NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506) 6-23
6-2
Setting
Tag
Data
Links
6
6-2-2
Tag
Data
Link
Setting
Procedure
6 Tag Data Link Functions
Drag icons from the
hardware list. Select
device icons with the
same major CIP
revision (Rev £).
The device names and major CIP revisions (Rev £) are displayed in the hardware list.
For the NJ/NX-series Controllers, device names of Units and major CIP revisions are as shown
in the following table.
CIP revisions
Device name in
Unit version Revision name in
Hardware List Major revision
Hardware List
NX701 Unit version 1.10 or later 2 None
NX502-££££ Unit version 1.60 or later 2 None
NX102-££££ Unit version 1.30 or later 2 None
NX1P2 Unit version 1.13 or later 2 None
NJ501-££££ Unit version 1.00 to 1.02 1 Rev1
Unit version 1.03 or later 2 Rev2
NJ301-££££ Unit version 1.01 or 1.02 1 Rev1
Unit version 1.03 or later 2 Rev2
NJ101 Unit version 1.10 or later 2 None
6-24 NJ/NX-series CPU Unit Built-in EtherNet/IP Port User’s Manual (W506)
6 Tag Data Link Functions
Precautions for Correct Use
Make sure that you select the devices with the same device names and the same major CIP
revisions as the devices you use in the actual operation. The following will occur if any device
name or CIP revision is incorrect when you attempt to download tag data link parameters on the
Network Configurator.
• If a device name is incorrect, an error message will be displayed saying “Specified device
can not be accessed, or wrong device type”, and the download will fail.
• If a revision is incorrect, a message will be displayed saying “Wrong unit revision”, and the
download will fail.
Similarly, the above will occur when performing upload or comparison of the tag data link pa-
rameters.
In any of the above cases, refer to 6-2-17 Changing Devices on page 6-81 and change the
device.
2
Right-click the registered device’s icon to display the pop-up menu, and select Change Node
Address.
3
Set the IP address to match the node address (IP address) actually used in the device, and
click the OK Button.
4
Repeat steps 1 to 3, and register all devices to which tag data links are made.
6-2-4 Creating Tags and Tag Sets
You must create tag sets and member tags that are required to create connections for a registered
built-in EtherNet/IP port and EtherNet/IP Unit. You can set the network variables used in control pro-
grams for tags.
This section first describes the basic procedure to create tags and tag sets, as described in (1) below.
Then it explains how to import variables with a Network Publish attribute from the Sysmac Studio to
the Network Configurator, as described in (2) below.