
7-3
7 Using Modbus-RTU Slave Mode
CJ-series Serial Communications Units Operation Manual for NJ-series CPU Unit(W494)
7-1
Modb
u
s
-R
TU Sla
v
e
S
y
stem
7
7-1
-3
Comm
unicating with
N
J
-ser
ies CPU Units Using Modb
us
There are four data models that are defined for Modbus.
Settings in the device variable for CJ-series Unit for System Settings are used to allocate each area of
these data models in the memory used for CJ-series Unit of the NJ-series CPU Unit for use by the
Serial Communications Unit.
Modbus data model areas
Allocated CJ Unit memory of NJ-series CPU Unit
1 Discrete Inputs:
CIO Area (fixed)
2 Coils:
CIO, Work, Holding, or Auxiliary Area
3 Input Registers:
CIO, Work, Holding, or Auxiliary Area
4 Holding Registers:
DM or EM Area
The Modbus-RTU command that accesses a specific Modbus data model is used to read and write
memory areas used for CJ-series Unit in the NJ-series CPU Unit. It is also necessary to allocate user-
defined variables when accessing the memory used for CJ-series Unit from the user program. For
details on creating user-defined variables, refer to 2-2-2 How to Specify and Create Variables.
Refer to 7-2 Device Variables for CJ-series Unit and System-defined Variables (Modbus-RTU Slave
Mode) for the setting allocation areas using system settings.
Refer to 7-3 Command and Response Details for details on Modbus-RTU commands.
Precautions for Safe Use
System Settings become valid when the Controller is reset, when the Serial Communications
Unit is restarted, or when the port is restarted. If any of the allocations are changed, reset the
Controller or restart the Serial Communications Unit or port after the safety of the connection
destination is confirmed.
7-1-3
Communicating with NJ-series CPU Units Using Modbus
Modbus Data Models
Discrete Inputs
Coils
Input Registers
Holding Registers
1
2
3
:
1
2
3
:
1
2
3
:
1
2
3
:
CIO
WR
HR
DM
0
1
2
:
0
1
2
:
0
1
2
:
0
1
2
:
EM
0
1
2
:
Modbus-RTU command
Modbus Commands
Read Coils
Read Discrete Inputs
Read Holding Registers
Read Input Registers
Write Single Coil
Write Single Register
Write Multiple Coils
Write Multiple Registers
User-defined
variable
User program
NJ-series CPU Unit
Serial Communications Unit
Memory used for CJ-series Unit
Use the settings of device variables for
CJ-series Unit for System Settings to
allocate the area for each data model
except for discrete inputs.
Содержание CJ1W-SCU22
Страница 192: ...4 Using Protocol Macros 4 56 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 250: ...6 No protocol Mode 6 22 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 460: ...A Standard System Protocol R 126 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 473: ...Index 1 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494 I Index...