9 - 41
9 Setting Up Slave Terminals
NX-series EtherCAT Coupler Unit User’s Manual (W519)
9-6 Precautions in Changing the Unit Configuration
9
9-6-1 I/O Data That Require Specification of NX Unit Num-
bers
9-6 Precautions in Changing the Unit
Configuration
This section provides precautions that apply after changing the Unit configuration of an EtherCAT Slave
Ter mi n a l.
You must specify the NX Unit number to access some I/O data. If you change the Unit configuration of
an EtherCAT Slave Terminal, you must correct the specified NX Unit numbers, such as those in pro-
grams.
The NX Unit Registration Status and NX Unit Error Status that are described in 9-2-4 I/O Allocation
Information on page 9-13 are examples of I/O data that is accessed by specifying the NX Unit number.
The I/O data for this status information uses BOOL arrays, and the NX Unit number is specified as the
subscript.
For example, if an NX Unit (F in the bottom figure) is added to the Slave Terminal, the NX Unit numbers
of all NX Units to the right of the new NX Unit (C to E in the bottom figure) will change.
If you specify the subscripts of arrays directly with numbers, the subscripts in the program must be cor-
rected to specify the same NX Unit as before the addition.
If you use _sNXUNIT_ID data type variables that are assigned to the Units to specify the array sub-
scripts, you do not need to correct the program even if the Unit configuration changes. The NX Unit
number of a Unit is stored in the UnitNo member of the _sNXUNIT_ID structure variable.
9-6-1 I/O Data That Require Specification of NX Unit Numbers
NX Unit number
NX Unit Registration Status
Note: NxReg[ ] is the variable that is assigned to the NX Unit Registration Status.
NX Unit F added as 3rd NX Unit
EtherCAT
Coupler Unit
NX
Unit A
NX
Unit B
NX
Unit C
NX
Unit D
NX
Unit E
NX
Unit A
NX
Unit B
NX
Unit C
NX
Unit F
NX
Unit D
NX
Unit E
EtherCAT
Coupler Unit
12345
NxReg[1] NxReg[2] NxReg[3] NxReg[4] NxReg[5]
12345
NxReg[1] NxReg[2] NxReg[3] NxReg[4] NxReg[5]
6
NxReg[6]
The addition changes the NX Unit numbers, so you must
correct the subscripts to specify the same NX Units as
before the addition in the NX Unit Registration Status.