Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
Version 1.03
2MODBUS Programmable I/O NA-9379FnIO S-Series
DOCUMENT CHANGE SUMMARY
REV
PAGE
REMARKS
DATE
EDITOR
1.0
New Document
Draft
2013/04/05
JE Kang
1.01
Reorganize
Draft
2014/03/25
YMKIM
1.02 Modify the Pin Description
2014/05/08
YMKIM
1.03
Reorganize2
Draft
2014/05/29
YMKIM
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
3MODBUS Programmable I/O NA-9379FnIO S-Series
CONTENTS
1. Important Notes ......................................................................................................................................................... 7
2. S-Series System ........................................................................................................................................................... 9
3.1. General Specification ............................................................................................................................. 11
4.2. LED Indicator ............................................................................................................................................. 14
3.2.1. Indicator Status and Flash Rates ...................................................................................................... 14
3.2.2. Module Status LED (MOD) ................................................................................................................. 15
3.2.3. Network Status LED (NET) .................................................................................................................. 15
3.2.4. PLC Run/Stop Status LED (RUN) ...................................................................................................... 15
3.2.5. Extension Module Status LED (I/O) ................................................................................................ 16
3.2.6. Field Power Status LED ........................................................................................................................ 16
3.3. RJ-45 Socket , RS232/485 Port ......................................................................................................... 17
5.7. RTC(Real Time Clock) Function ......................................................................................................... 35
6. Programing the PIO (CoDeSys) .......................................................................................................................... 36
6.1. Download and Install the CoDeSys ................................................................................................ 36
6.2. The Basic Configuration CoDeSys ................................................................................................... 37
6.2.1. Installation of XML ................................................................................................................................. 37
6.2.2. Created Project ........................................................................................................................................ 41
6.2.3. CoDeSys User Interface ........................................................................................................................ 42
A.4.2. Adapter Identification Special Register (0x1000, 4096) ........................................................ 72
A.4.3. Adapter Watchdog Time, other Time Special Register (0x1020, 4128) ......................... 73
A.4.4. Adapter Information Special Register (0x1100, 4352) ........................................................... 74
A.4.5. Adapter Setting Special Register (0x1600, 5632) ..................................................................... 75
A.4.6. Expansion Slot Information Special Register (0x2000, 8192) ............................................. 76
A.5 Example ....................................................................................................................................................... 78
A.5.1. Example of Input Process Image(Input Register) Map .......................................................... 78
A.5.2. Example of Output Process Image(Output Register) Map .................................................. 80
APPENDIX B - Product List ........................................................................................................................................... 84
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
7MODBUS Programmable I/O NA-9379FnIO S-Series
Warning!
Caution!
1. Important Notes
Solid state equipment has operational characteristics differing from those of electromechanical equipment.
Safety Guidelines for the Application, Installation and Maintenance of Solid State Controls describes some important
differences between solid state equipment and hard-wired electromechanical devices.
Because of this difference, and also because of the wide variety of uses for solid state equipment, all persons
responsible for applying this equipment must satisfy themselves that each intended application of this equipment is
acceptable.
In no event will CREVIS be responsible or liable for indirect or consequential damages resulting from the use or
application of this equipment.
The examples and diagrams in this manual are included solely for illustrative purposes. Because of the many variables
and requirements associated with any particular installation, CREVIS cannot assume responsibility or liability for actual
use based on the examples and diagrams.
If you don’t follow the directions, it could cause a personal injury, damage to the equipment or explosion
•Do not assemble the products and wire with power applied to the system. Else it may cause an electric arc, which
can result into unexpected and potentially dangerous action by field devices. Arching is explosion risk in
hazardous locations. Be sure that the area is non-hazardous or remove system power appropriately before
assembling or wiring the modules.
•Do not touch any terminal blocks or IO modules when system is running. Else it may cause the unit to an electric
shock or malfunction.
•Keep away from the strange metallic materials not related to the unit and wiring works should be controlled by the
electric expert engineer. Else it may cause the unit to a fire, electric shock or malfunction.
If you disobey the instructions, there may be possibility of personal injury, damage to equipment or
explosion. Please follow below Instructions.
•Check the rated voltage and terminal array before wiring. Avoid the circumstances over 55℃ of temperature.
Avoid placing it directly in the sunlight.
• Avoid the place under circumstances over 85% of humidity.
• Do not place Modules near by the inflammable material. Else it may cause a fire.
• Do not permit any vibration approaching it directly.
• Go through module specification carefully, ensure inputs, output connections are made with the specifications. Use
standard cables for wiring.
•Use Product under pollution degree 2 environment.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
8MODBUS Programmable I/O NA-9379FnIO S-Series
1.1. Safety Instruction
1.1.1. Symbols
Identifies information about practices or circumstances that can cause an explosion in a
hazardous environment, which may lead to personal injury or death property damage or
economic loss.
Identifies information that is critical for successful application and understanding of the
product.
Identifies information about practices or circumstances that can lead to personal
injury, property damage, or economic loss.
Attentions help you to identity a hazard, avoid a hazard, and recognize the consequences.
1.1.2. Safety Notes
The modules are equipped with electronic components that may be destroyed by electrostatic
discharge. When handling the modules, ensure that the environment (persons, workplace and
packing) is well grounded. Avoid touching conductive components.
1.1.3. Certification (TBD)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
9MODBUS Programmable I/O NA-9379FnIO S-Series
2. S-Series System
2.1.Electrical Interface
• Network Adapter Module
The Network Adapter Module forms the link between the field bus and the field devices with the Expansion Modules.
The connection to different field bus systems can be established by each of the corresponding Network Adapter
Module, e.g. for SyncNet, PROFIBUS, CANopen, DeviceNet, Ethernet/IP, CC-Link, MODBUS/Serial,
MODBUS/TCP etc.
• Expansion Module
The Expansion Modules are supported a variety of input and output field devices. There are digital and analog
input/output modules and special function modules.
• Two types of Message
Service Messaging / I/O Messaging
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
10MODBUS Programmable I/O NA-9379FnIO S-Series
2.2. I/O Process Image Map
An expansion module may have 3 types of data as I/O data, configuration parameter and memory register.
The data exchange between network adapter and expansion modules is done via an I/O process image data by
internal-protocol. The following figure shows the data flow of process image between network adapter and
expansion modules.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
11MODBUS Programmable I/O NA-9379FnIO S-Series
General Specification
System Power
Supply voltage : 24Vdc nominal
Supply voltage range : 11~28.8Vdc
Protection : Output current limit (Min. 1.5A)
Reverse polarity protection
Power Dissipation
110mA typical @ 24Vdc
Current for I/O Module
1.5A @5Vdc
Isolation
System power to internal logic : Non-isolation
System power I/O driver : Isolation
Field Power
Supply voltage : 24Vdc nominal
Supply voltage range : 11~28Vdc
Max. Current Field Power Contact
DC 10A Max.
Weight
172g
Module Size
54mm x 99mm x 70mm
Environment Condition
Environmental Specifications
Operating Temperature
Storage Temperature
Relative Humidity
Mounting
-20℃~60℃
-40℃~85℃
5% ~ 90% non-condensing
DIN rail
General Specifications
Shock Operating
IEC 60068-2-6
Vibration/shock resistance
Based on IEC 60068-2-6
Sine Vibration
- 10 ~ 25 Hz : 0.5mm
- 50 ~ 150 Hz : 5g
- 150 ~ 1000 Hz : 2g
- Sweep Rate : 1 Oct/min, 50 cycles
Sine Vibration
- 10 ~ 25 Hz : 0.03 g²/Hz
- 25 ~ 50 Hz : 0.05 g²/Hz
- 50 ~ 150 Hz : 0.15 g²/Hz
- 150 ~ 1000 Hz : 0.01 g²/Hz
- Test time : 5hrs for each test
EMC resistance burst/ESD
EN 61000-6-2 : 2005
EN 61000-6-4/ALL : 2011
Installation Pos. / Protect. Class
Variable/IP20
Product Certifications
TBD
3. Specification
3.1. General Specification
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
12MODBUS Programmable I/O NA-9379FnIO S-Series
Programmable Specification
Programming
CoDeSys V3.5 SP3 Patch 1
Program Memory
512 Kbytes
Data Memory
512 Kbytes
%IW0~%IW639 (640 word Input and Internal memory)
%QW0~%QW639 (640 word Output and Internal memory)
%MW0~%MW639 (640 word Internal memory)
Non-Volatile Memory
32 Kbytes (Retain : 16Kbytes, Flag : 16Kbytes
Run-Time system
Multiple PLC Task
Program Languages
IEC 61131-3 (LD, IL, ST, FBD, SFC)
RTC
Retain Time : 6 days
Accuracy : <2min/month
Max. Task
2
Max. Cycle Task
2
Max. Status Task
1
Process Time
3us (100Instruction)
Interface Specification
Adapter Type
Master & Slave Node (MODBUS TCP)
Max. Expansion Module
32 slots
Max. Input Size
126 Words (252 Byte)
Max. Output Size
126 Words (252 Byte)
Max. Nodes
Limited by Ethernet Specification
Baudrate
10/100Mps, Auto-negotiation, Full Duplex
Interface Connector
RJ-45 socket * 2pcs
Protocol
MODBUS TCP, DHCP, BOOTP, SNMP
Max. Socket
18 (UDP : 6, TCP : 12, TCP_LISTEN : 6)
Other Serial Port
RS232/485 for MODBUS RTU, Touch Pannel or IOGuide
Serial Configuration (RS232/485)
Node : 1(default)
Baudrate : 38400(default)
Data bit : 8(default)
Parity bit : No parity(default)
Stop bit : 1(default)
Indicator
4 LEDs(NET LED is Not used)
1 Green/Red, Module Status (MOD)
1 Green/Red, Run Status (RUN)
1 Green/Red, Extension Module Status (I/O)
1 Green, Field Power Status
3.2. Interface Specification
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
13MODBUS Programmable I/O NA-9379FnIO S-Series
4. Module Description
4.1. NA-9379 (MODBUS Programmable I/O)
The modules are not hot swappable and should be not removed in power on condition.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
14MODBUS Programmable I/O NA-9379FnIO S-Series
LED is:
Constantly on
LED Off
Constantly off
LED Flickering
Equal on and off times with a frequency of approximately 10 Hz: on for approximately
50ms and off for approximately 50ms.
LED Blinking
Equal on and off times with a frequency of approximately 2, 5Hz: on for approximately
200ms followed by off for approximately 200ms.
LED Single flash
One short flash (approximately 200ms) followed by a long off phase (approximately
1000ms)
LED Double flash
A sequence of two short flashes (approximately 200ms), separated by an off phase
(approximately 200ms). The sequence is finished by a long off phase (approximately
1000ms).
LED Triple flash
A sequence of three short flashes (approximately 200ms), separated by an off phase
(approximately 200ms). The sequence is finished by a long off phase (approximately
1000ms).
LED No.
LED Function /
Description
LED Color
MOD
Module Status
Green/Red
NET
Not Used
-
RUN
Error Status
Green/Red
I/O
Extension module Status
Green/Red
Field Power
Field Power Enable
Green
4.2. LED Indicator
3.2.1. Indicator Status and Flash Rates
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
15MODBUS Programmable I/O NA-9379FnIO S-Series
State
LED is :
To indicate :
No Power
Off
No power is supplied to the unit.
Device Operational
Green
The unit is operating in normal condition.
Device in Standby
Blinking Green
The EEPROM parameter is not initialized yet.
Serial Number is zero value (0x00000000)
IAP Mode
Flashing Green
IAP Mode : Available for firmware download using FireFox.
Minor Fault
Blinking Red
The unit has occurred recoverable fault in self-testing.
- EEPROM checksum fault
Unrecoverable Fault
Red
The unit has occurred unrecoverable fault in self-testing.
- Firmware fault
State
LED is :
To indicate :
Not Used
State
LED is :
To indicate :
Not Programmed
OFF
Not Power is supplied or the unit or Not programmed
Run
ON
PLC Run
Stop
Blinking Green
PLC Stop
Error
Blinking Red
Failure of Module Configuration
3.2.2. Module Status LED (MOD)
3.2.3. Network Status LED (NET)
3.2.4. PLC Run/Stop Status LED (RUN)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
16MODBUS Programmable I/O NA-9379FnIO S-Series
State
LED is :
To indicate :
Not Powered
No Expansion Module
Off
Device has no expansion module or may not be powered
On-line,
Do not Exchanging I/O
Flashing Green
Extension module is normal but does not exchanging I/O data
(Passed the expansion module configuration).
Connection,
Run Exchanging IO
Green
Exchanging I/O data
Connection fault
during exchanging IO
Red
One or more expansion module occurred in fault state.
- Changed expansion module configuration.
- expansion module communication failure.
Expansion
Configuration Failed
Flashing Red
Failed to initialize expansion module
- Detected invalid expansion module ID.
- Overflowed Input / Output Size
- Too many expansion module
- Initial protocol failure
- Mismatch vendor code between adapter and expansion module.
State
LED is :
To indicate :
Not Supplied Field Power
Off
Not supplied 24V dc field power, 5Vdc System Power.
Supplied Field Power
Green
Supplied 24V dc field power, 5Vdc System Power.
3.2.5. Extension Module Status LED (I/O)
3.2.6. Field Power Status LED
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
17MODBUS Programmable I/O NA-9379FnIO S-Series
RJ-45
Signal Name
Description
1
TD+
Transmit + 2 TD-
Transmit - 3 RD+
Receive + 4 - 5
-
6
RD-
Receive -
7
- 8
-
Case
Shield
RS 232/485
Signal Name
Description
1
-
2
RXD
RS232 RXD
3
TXD
RS232 TXD
4
-
5
GND
RS232 GND
6
D+
RS 485 D+ 7 - 8
D-
RS485 D- 9 -
Toggle Switch Status
Module is
Description
UP
RUN
PLC Run
DOWN
STOP
PLC Stop
(Fault Action is performed)
Push Button
Module is
Description
Press and release.
Reset
Reset the PLC and then stop.
Hold down and reset
the power.
IAP mode
Available for firmware download
using FireFox
3.3. RJ-45 Socket , RS232/485 Port
3.4. Toggle Switch , Push Button
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
18MODBUS Programmable I/O NA-9379FnIO S-Series
Pin
Signal Description
Signal Description
Pin
0
System Power 24V
System Power 0V
1
2
F.G
F.G
3 4 Field Power 0V
Field Power 0V
5
6
Field Power 24V
Field Power 24V
7
No.
Name
Description
1
System Vcc
System supply voltage (5V dc).
2
System GND
System Ground.
3
Token Output
Token output port of Processor module.
4
Serial Output
Transmitter output port of Processor
module.
5
Serial Input
Receiver input port of Processor module.
6
Reserved
Reserved for bypass Token.
7
Field GND
Field Ground.
8
Field Vcc
Field supply voltage (24Vdc).
3.5. RTB Terminal Block
- System Power: The power for starting up CPU.
- Field Power: The power for input and output line.
Do not use an incorrect voltage/frequency!
The use of an incorrect supply voltage or frequency
can cause severe damage to the component.
3.6. Pin Description
Communication between the Network adapter and the expansion module as well as system / field power supply of the
bus modules is carried out via the internal bus. It is comprised of 6 data pin and 2 field power pin.
Do not touch data and field power pins in order to
avoid soiling and damage by ESD noise.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
19MODBUS Programmable I/O NA-9379FnIO S-Series
3.7. Dimension
(mm)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
20MODBUS Programmable I/O NA-9379FnIO S-Series
4. Mechanical Setup
4.3. Inserting and Removing the Module.
As above figure in order to safeguard the FnIO module from jamming, it should be fixed onto the DIN rail with locking
level. To do so, fold on the upper of the locking lever.
To pull out the FnIO module, unfold the locking lever as below figure.
Before work is done on the components, the voltage supply must be turned off.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
21MODBUS Programmable I/O NA-9379FnIO S-Series
4.4. Removable Terminal Block (RTB)
4.5. Method of Wiring.
Connecting or removing the cable by pushing the terminal button for the relevant points.
The use of an incorrect supply voltage or frequency can cause severe damage to the
component.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
22MODBUS Programmable I/O NA-9379FnIO S-Series
5. Various Functions of PIO (With IO Guide Pro)
Crevis IO Guide Pro is compatible with the PIO(NA-9379).
The basic parameter set-up and configuration for the PIO is available via the IO Guide Pro.
5.1. Connect IO Guide Pro (MODBUS Serial)
(1) Installation program-IO Guide Pro that provides CREVIS(www.crevis.co.kr).
(2) Open the IO Guide and Click on the ‘New project’ Icon.
(2) Write the ‘Project Name’ and Select of bus type Specify the local and Click on the ‘OK’ button.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
23MODBUS Programmable I/O NA-9379FnIO S-Series
(1) After creating a project and click the ‘Automatic scan’ Icon.
(4) Write the value(Port, node, Baudrate) click the ‘Automatic scan’ button.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
24MODBUS Programmable I/O NA-9379FnIO S-Series
(1) After the scan completes, click the ‘OK’ button.
(1) It is ready to use the IO Guide Pro.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
25MODBUS Programmable I/O NA-9379FnIO S-Series
5.2. Confirmation of Network Information.
You can see by checking the IP Address , Subnet Mask, Gate Way, Mac Address of NA-9379 .
* IP Address : Also known as an "IP number" or simply an "IP," this is a code made up of numbers separated by
three dots that identifies a particular computer on the Internet. Every computer, whether it be a Web server or the
computer you're using right now, requires an IP address to connect to the Internet. IP addresses consist of four sets
of numbers from 0 to 255, separated by three dots.
* Subnet Mask : A subnet mask is a number that defines a range of IP addresses that can be used in a network. (It
is not something you wear on your head to keep subnets out.) Subnet masks are used to designate sub networks, or
subnets, which are typically local networks LANs that are connected to the Internet. Systems within the same
subnet can communicate directly with each other, while systems on different subnets must communicate through a
router.
* Gate Way : A gateway is either hardware or software that acts as a bridge between two networks so that data can
be transferred between a number of computers.
* Mac Address : A MAC address is a hardware identification number that uniquely identifies each device on a
network. The MAC address is manufactured into every network card, such as an Ethernet card or Wi-Fi card, and
therefore cannot be changed.
(1) Run ‘[Crevis] -> [IOGuidePro] -> [Protocol Messenger] -> [Modbus]’
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
26MODBUS Programmable I/O NA-9379FnIO S-Series
(2) Write the value of each.
*Protocol : Modbus RTU
*ComPort : User Port / Baudrate : 38400(default)
*Address(Hex) : 1600 (IP Address Register)
:1602 (IP Subnet Mask Register)
:1604 (Gate way Register)
:1610 (Mac Address Register)
*Function(Dec) : 03, Read Holding Registers
(3) After clicking the ‘send’ button and confirm the necessary information.
If you choose to 'ByteDec', More easy to see.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
27MODBUS Programmable I/O NA-9379FnIO S-Series
5.3. BootP/DHCP Setting
You can selected to ‘IP Setting method’.
* BOOTP: short for Bootstrap Protocol, is a UDP network protocol used by a network client to obtain its IP
address automatically. This is usually done in the bootstrap process of computers or operating systems running on
them. The BOOTP servers assign the IP address from a pool of addresses to each client.
* DHCP: set of rules used by communications devices such as a computer, router or network adapter to allow the
device to request and obtain an IP address from a server which has a list of addresses available for assignment.
(1) Run ‘[Crevis] -> [IOGuidePro] -> [Protocol Messenger] -> [Modbus]’
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
29MODBUS Programmable I/O NA-9379FnIO S-Series
5.4. Setup IP Address
You can assign the IP Address manually via the setting of Bootp server.
Default IP Address is 192.168.100.100
(1) Run ‘[Crevis] [IOGuidePro] [Bootp Server]’
NA9379 is a model that supports DHCP and Bootp.
If you have a DHCP server on the same communications,
IP settings from Bootp is impossible.
In this case, set the IP from the DHCP server.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
30MODBUS Programmable I/O NA-9379FnIO S-Series
(2) Power on the NA9379, and Click the ‘Start Bootp’ button.
(3) Double Click ‘MAC address of NA9379’
Turn on the power of NA-9379, and Retry 2imes for 4 seconds.
IP settings will be within that time.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
31MODBUS Programmable I/O NA-9379FnIO S-Series
(4) Set the IP, and click ‘OK’.
(5) Finish
Subnet Mask and Gateway is
assigned automatically by the value that is set in the computer.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
Setting according to the each communication state is possible Because NA-9379 is available the
RS232 and RS485 Serial Communications.
• Station Setting
The following illustration is an area of Register 0x160A address that can be used to set the code of Serial
communication. High 1byte is the area of rs232, and Low 1byte is the area of rs485.
It is possible to set a maximum of 247 for each area. (default : 1)
MSB LSB
RS232C Modbus station RS485 Modbus station
• RS232/ RS485 Communication setting
The options for the communication can be selected.
RS232 can be selected from the register address, “0x1606”.
RS485 can be selected from the register address, “0x1608”.
MSB LSB
Data bit Stop bit Parity bit Reserve
MSB LSB
Data bit Stop bit Parity bit Reserve
RS485
• Baudrate setting
The baudrate from 1200bps to 115200bps is supported.
RS232 can be selected from the register address, “0x1606”.
RS485 can be selected from the register address, “0x1608”.
RS232
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
33MODBUS Programmable I/O NA-9379FnIO S-Series
(1) Run ‘[Crevis] -> [IOGuidePro] -> [Protocol Messenger] -> [Modbus]’
(2) Write the value of each.
*Protocol : Modbus RTU
*ComPort : User Port / Baudrate : 38400(default)
*Address(Hex) : 1606 (RS232 Baudrate Register)
:1607 (RS232 Use bit Setting Register)
:1608 (RS485 Baudrate Register)
:1609 (RS485 Use bit Setting Register)
*Function(Dec) : When the value is write - 16, Write Multiple registers
When the value is read - 03, Read Holding Registers
(3) confirm the necessary information.
*When the value is write *When the value is read
write the desired value and click the Send button. Click the Send button and confirm the value.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
34MODBUS Programmable I/O NA-9379FnIO S-Series
5.6. Memory Reset
data field 0x55AA makes the remote device to restart with factory default setup of EEPROM.
*All expansion slot configuration parameters are cleared.
(1) Run ‘[Crevis] -> [IOGuidePro] -> [Protocol Messenger] -> [Modbus]’
(2) Write the value of each.
*Protocol : Modbus RTU
*ComPort : User Port / Baudrate : 38400(default)
*Address(Hex) : 0001 (Factory default setup)
*Function(Dec) : When the value is write – 08, Diagnostics
(3) Write the register value and click the ‘Send’ button.
*Value : 0x55AA
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
35MODBUS Programmable I/O NA-9379FnIO S-Series
5.7. RTC(Real Time Clock) Function
A real-time clock (RTC) is a computer clock (most often in the form of an integrated circuit) that keeps
track of the current time. RTC information of NA-9379 is stored in address 0x1620 in the Register,
also can be read.
(1) Run ‘[Crevis] -> [IOGuidePro] -> [Protocol Messenger] -> [Modbus]’
(2) Write the value of each.
*Protocol : Modbus RTU
*ComPort : User Port / Baudrate : 38400(default)
*Address(Hex) : 1620 (RTC Register)
*Function(Dec) : When the value is write - 16, Write Multiple registers
When the value is read - 03, Read Holding Registers
(3) confirm the necessary information.
*When the value is write *When the value is read
write the desired value and click the Send button. Click the Send button and confirm the value.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
36MODBUS Programmable I/O NA-9379FnIO S-Series
6. Programing the PIO (CoDeSys)
6.1. Download and Install the CoDeSys
Please use the CoDeSys version V3.5.3.1 (V3.5 SP3 Patch 1)
Except for the above version, any versions including the latest version
will not be allowed for PIO(NA-9379).
Unzip the downloaded file, and Installation ‘Setup_CoDeSysV35SP3Patch1.exe’
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
37MODBUS Programmable I/O NA-9379FnIO S-Series
6.2. The Basic Configuration CoDeSys
6.2.1. Installation of XML
(1) Run the CoDeSys program
(2) [Tools] [Options], Click ‘Predefined feature sets…’
(3) Standard Professional, Click ‘OK’
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
38MODBUS Programmable I/O NA-9379FnIO S-Series
(4) Click ‘OK’
(5) [Tools] [Device Repository], Click ‘PLCs’ and select PIO Description (download to CREVIS
website), Install…
(ProgrammableIO_NA9379.devdesc.xml)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
39MODBUS Programmable I/O NA-9379FnIO S-Series
*Please check whether they are installed correctly or not.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
40MODBUS Programmable I/O NA-9379FnIO S-Series
(6) [Tools] [Device Repository], Click ‘Miscellaneous’ and install the slot description and I/O
Description (download to CREVIS website).
(ST-xxxx.devdesc.xml)
*Please check whether they are installed correctly or not.
(CVSRACK.devdesc.xml)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
41MODBUS Programmable I/O NA-9379FnIO S-Series
6.2.2. Created Project
(1) Run the CoDeSys program.
(2) [File] [New Project], select ‘Standard project’. Write the Project Name and Location.
Click ‘OK’
(3) Select Device : NA9379, select the Programming Language.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
42MODBUS Programmable I/O NA-9379FnIO S-Series
6.2.3. CoDeSys User Interface
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
43MODBUS Programmable I/O NA-9379FnIO S-Series
6.2.4. Setup I/O
(1) Additional Device
Click on the model you want to use, and click ‘Plug Device’.
For the normal operation, you must select the module image in order through the CoDeSys
like the user configuration.
Auto Scan is not supported.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
44MODBUS Programmable I/O NA-9379FnIO S-Series
(2) Setting Device Parameter and IO Mapping
Click IO Right click Click ‘Edit object’.
• Parameter setting
Click ‘Digital IOs Configuration’
* The setting unit of the parameter is bytes.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
45MODBUS Programmable I/O NA-9379FnIO S-Series
• IO Mapping
Click ‘Digital IOs I/O Mapping’
If there are no set values in the red square, you can program the variable area set by the address.
If you use the variable set by the POU or GVL, you can use the variable area after deleting the variable in the
address.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
46MODBUS Programmable I/O NA-9379FnIO S-Series
6.3. MODBUS TCP Setting
(1) Add Device
Click Device(NA9379) right click Click ‘Add Device…’.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
49MODBUS Programmable I/O NA-9379FnIO S-Series
(5) Configuration the ModbusTCP Slave
Click ‘Modbus_TCP_Slave’(Modbus TCP Slave)
Write Slave IP Address (NA-9379)
Click ‘Modbus Slave Channel’
Add a channel of NA-9379 and Modify Cycle Time
* Default Cycle Time(ms) : 100ms.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
50MODBUS Programmable I/O NA-9379FnIO S-Series
6.4. Network Variable
(1) Click ‘Application’ Right click and click ‘Add Object’ Click ‘Network Variable List (Sender)’.
* You have to add one more devices in the devices tree.
(2) Define the network properties of the sender GVL
* You have to select UDP as network type.
* List identifier and Node ID is the same concept.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
51MODBUS Programmable I/O NA-9379FnIO S-Series
(3) Add a Global Network Variable List in the Receiver
* You find a selection list of all GVLs with network properties currently available in the project.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
52MODBUS Programmable I/O NA-9379FnIO S-Series
(4) Created by Global Variables.
(5) It is possible to create a program using a global variable.
- in prog_sender in the sender application enter the following use of variable iglobvar.
- in prog_Receiver in the receiver application also use variable iglobvar.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
53MODBUS Programmable I/O NA-9379FnIO S-Series
6.5. Download and Monitoring
(1) Scan network
[Device] [Communication Settings], click ‘Scan network’.
After completing the search, double click the Gateway icon to make it activated.
(2) Login
[Online] [Login] Download to Application Entry into Monitoring Mode [Debug] [RUN]
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
54MODBUS Programmable I/O NA-9379FnIO S-Series
7. Upgrade Firmware
7.1. Using IAP over Ethernet
Using Firefox, can download the firmware.
(1) Apply a power with pushing a reset button.
(2) Execute Firefox
(3) Connect to 192.168.100.10 and login (User ID :1 / Password : 1)
(4) Search the file to download using a search button.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
55MODBUS Programmable I/O NA-9379FnIO S-Series
(5) Click a Upload Button.
(6) If it finish, you can see a below message (File Upload Done!)
And click a ‘reset mcu’ button.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
56MODBUS Programmable I/O NA-9379FnIO S-Series
LED Status
Cause
Action
All LED turns off
- No power
- Check main power Cable
- System power is not supplied.
- Contact Sales team and send module
for repair.
MOD LED flashes green
- Failure of initialization EEPROM
parameter.
- Contact Sales team and send module
for repair.
MOD LED flashes red
- Excess of expansion slot
- Excess of IO size
- Wrong IO composition
- Occurrence of EEPROM checksum
error
- Use expansion slot up to 32.
- Compose that IO total size is not
excess.
- Check composition I/O Module
MOD LED is red
- Wrong address ID
- Occurrence critical error in firmware
- Contact Sales team and send module
for repair.
I/O LED turns off
- Failure of realization expansion Module
- None expansion Module
- Check connector status both NA
series and expansion module.
I/O LED flashes red
-Failure of configuration baud rate
- Check communication cable with
Master
- Check power for master.
-Failure of initialization I/O
- Use expansion slot up to 32.
- Compose that IO total size is not
excess.
NA series notice unidentified
expansion module ID. Check status of
expansion module.
I/O LED is red
-Failure of exchanging I/O data
Check status of expansion IO
connection.
RUN LED flashed red
-Failure of Module Configuration
Check the module hardware and
software configurations are the same.
8. Trouble Shooting
8.1.How to diagnose by LED indicator
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
57MODBUS Programmable I/O NA-9379FnIO S-Series
8.2. How to diagnose when device couldn’t communicate network
Inspection of wrong or omission cable connection.
- Check status of cable connection for each node.
- Check that all color matches between connector and cable.
- Check wire omission.
Terminator resistor
- If terminator resistor is not installed, install terminator resistor
- Check location of terminator resistor
Configuration of Node address
- Check duplication node address.
Configuration of Master
- Check configuration of master
- Check whether to do download or don’t
- Check composition is right
Configuration of communication baudrate
I/O size
Configuration of each node
Ground and environment
- Check ground is contacted
- Check environment factor (temperature, humidity, etc.) is in less than regular limit
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
58MODBUS Programmable I/O NA-9379FnIO S-Series
Start Address
Read/Write
Description
Func. Code
0x0000 ~
Read
Process input image registers (Real Input Register)
4, 23
0x0800 ~
Read/Write
Process output image registers (Real Output Register)
3, 16, 23
0x1000 ~
Read
Adapter Identification special registers.
3, 4, 23
0x1020 ~
Read/Write
Adapter Watchdog, other time special register.
3, 4, 6, 16,
23
0x1100 ~
Read/Write
Adapter Information special registers.
3, 4, 6, 16,
23
0x2000 ~
Read/Write
Expansion Slot Information special registers.
3, 4, 6, 16,
23
Start Address
Read/Write
Description
Func. Code
0x0000 ~
Read
Process input image bits
All input registers area is addressable by bit address.
Size of input image bit is size of input image register * 16.
2
0x0800 ~
Read/Write
Process output image bits
All output registers area is addressable by bit address.
Size of output image bit is size of output image register * 16.
1, 5, 15
APPENDIX A - MODBUS INTERFACE
A.1MODBUS Interface Register / Bit Map
• Register Map
• Bit Map
* The special register map must be accessed by read/write of every each address (one address).
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
59MODBUS Programmable I/O NA-9379FnIO S-Series
Start
Address
Function
Data
CRC Check
End
≥ 3.5 chars
1 char
1 char
Up to 252 chars
2 chars
≥ 3.5 chars
Start
Address
Function
Data
CRC Check
End
1 char
2 chars
2 chars
Up to 252 chars
2 chars
2 chars CR,LF
Function Code
Function
Description
Unicast / Broadcast
1 (0x01)
Read Coils
Read output bit
Unicast
2 (0x02)
Read Discrete Inputs
Read input bit
Unicast
3 (0x03)
Read Holding Registers
Read output word
Unicast
4 (0x04)
Read Input Registers
Read input word
Unicast
5 (0x05)
Write Single Coil
Write one bit output
Unicast / Broadcast
6 (0x06)
Write Single Register
Write one word output
Unicast / Broadcast
8 (0x08)
Diagnostics (Serial Line only)
Read diagnostic register
Unicast
15 (0x0F)
Write Multiple Coils
Write a number of output bits
Unicast / Broadcast
16 (0x10)
Write Multiple registers
Write a number of output words
Unicast / Broadcast
23 (0x17)
Read / Write Multiple register
Read a number of input words /
Write a number of output words
Unicast
A.2 MODBUS Transmission Mode
Two different serial transmission modes are defined: The RTU mode and the ASCII mode. It defines the bit
contents of message fields transmitted serially on the line. It determines how information is packed into the
message fields and decoded.
A.2.1. RTU Transmission Mode
When devices communicate on a MODBUS serial line using the RTU (Remote Terminal Unit) mode, each 8–bit
byte in a message contains two 4–bit hexadecimal characters. The main advantage of this mode is that its greater
character density allows better data throughput than ASCII mode for the same baudrate. Each message must be
transmitted in a continuous stream of characters.
A.2.2. ASCII Transmission Mode
When devices are setup to communicate on a MODBUS serial line using ASCII (American Standard Code for
Information Interchange) mode, each 8–bit byte in a message is sent as two ASCII characters. This mode is used
when the physical communication link or the capabilities of the device does not allow the conformance with RTU
mode requirement regarding timers management.
A.3 Supported MODBUS Function Codes
- Refer to MODBUS APPLICATION PROTOCOL SPECIFICATION V1.1a
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
60MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x01
0x01
“01”
0x30, 0x31
Starting Address Hi
0x10
0x10
“10”
0x31, 0x30
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Lo
0x0A
0x0A
“0A”
0x30, 0x41
Error Check (CRC/LRC)
-
0xB8, 0xAB
“DE”
0x44, 0x45
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x01
0x01
“01”
0x30, 0x31
Byte Count
0x02
0x02
“02”
0x30, 0x32
Output Status
0x55
0x55
“55”
0x35, 0x35
Output Status
0x02
0x02
“02”
0x30, 0x32
Error Check (CRC/LRC)
-
0x8F, 0x6D
“9F”
0x39, 0x46
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.1. 1 (0x01) Read Coils
This function code is used to read from 1 to 2000 contiguous status of coils in a remote device. The Request PDU
specifies the starting address, i.e. the address of the first coil specified, and the number of coils. In the PDU Coils
are addressed starting at zero. Therefore coils numbered 1-16 are addressed as 0-15. The coils in the response
message are packed as one coil per bit of the data field. Status is indicated as 1= ON and 0= OFF.
• Request
• Response
* In case of address 0x1015~0x1000 output bit value: 00000010_01010101.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
61MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x02
0x02
“02”
0x30, 0x32
Starting Address Hi
0x00
0x00
“00”
0x30, 0x30
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Inputs Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Inputs Lo
0x0A
0x0A
“0A”
0x30, 0x41
Error Check (CRC/LRC)
-
0xF8, 0x6B
“ED”
0x45, 0x44
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x02
0x02
“02”
0x30, 0x32
Byte Count
0x02
0x02
“02”
0x30, 0x32
Input Status
0x80
0x80
“80”
0x38, 0x30
Input Status
0x00
0x00
“00”
0x30, 0x30
Error Check (CRC/LRC)
-
0x50, 0x78
“75”
0x37, 0x35
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.2. 2 (0x02) Read Discrete Inputs
This function code is used to read from 1 to 2000 contiguous status of discrete inputs in a remote device. The
Request PDU specifies the starting address, i.e. the address of the first input specified, and the number of inputs. In
the PDU Discrete Inputs are addressed starting at zero. Therefore Discrete inputs numbered 1-16 are addressed as
0-15. The discrete inputs in the response message are packed as one input per bit of the data field.
Status is indicated as 1= ON; 0= OFF.
• Request
• Response
- In case of address 0x0015~0x0000 output bit value: 00000000_10000000.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
62MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x03
0x03
“03”
0x30, 0x33
Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Register Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Register Lo
0x02
0x02
“02”
0x30, 0x32
Error Check (CRC/LRC)
-
0xC6, 0x0D
“EC”
0x45, 0x43
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x03
0x03
“03”
0x30, 0x33
Byte Count
0x04
0x04
“04”
0x30, 0x34
Output Register #0 Hi
0x11
0x11
“11”
0x31, 0x31
Output Register #0 Lo
0x22
0x22
“22”
0x32, 0x32
Output Register #1 Hi
0x33
0x33
“33”
0x33, 0x33
Output Register #1 Lo
0x44
0x44
“44”
0x34, 0x34
Error Check (CRC/LRC)
-
0x2D, 0xC6
“38”
0x33, 0x38
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.3. 3 (0x03) Read Holding Registers
This function code is used to read the contents of a contiguous block of holding registers in a remote device. The
Request PDU specifies the starting register address and the number of registers.
The register data in the response message are packed as two bytes per register, with the binary contents right
justified within each byte. For each register, the first byte contains the high order bits and the second contains the
low order bits.
• Request
• Response
- In case of address 0x0800, 0x0801 output register value: 0x1122, 0x3344.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
63MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x04
0x04
“04”
0x30, 0x34
Starting Address Hi
0x00
0x00
“00”
0x30, 0x30
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Register Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Register Lo
0x02
0x02
“02”
0x30, 0x32
Error Check (CRC/LRC)
-
0x71, 0xAD
“F3”
0x46, 0x33
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x04
0x04
“04”
0x30, 0x34
Byte Count
0x04
0x04
“04”
0x30, 0x34
Input Register #0 Hi
0x00
0x00
“00”
0x30, 0x30
Input Register #0 Lo
0x80
0x80
“80”
0x38, 0x30
Input Register #1 Hi
0x00
0x00
“00”
0x30, 0x30
Input Register #1 Lo
0x00
0x00
“00”
0x30, 0x30
Error Check (CRC/LRC)
-
0x9C, 0x6C
“71”
0x37, 0x31
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.4. 4 (0x04) Read Input Registers
This function code is used to read from 1 to approx. 125 contiguous input registers in a remote device. The
Request PDU specifies the starting register address and the number of registers. The register data in the response
message are packed as two bytes per register, with the binary contents right justified within each byte. For each
register, the first byte contains the high order bits and the second contains the low order bits.
• Request
• Response
- In case of address 0x0000, 0x0001 input register value: 0x0080, 0x0000.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
64MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x05
0x05
“05”
0x30, 0x35
Starting Address Hi
0x10
0x10
“10”
0x31, 0x30
Starting Address Lo
0x01
0x01
“01”
0x30, 0x31
Quantity of Outputs Hi
0xFF
0xFF
“FF”
0x46, 0x46
Quantity of Outputs Lo
0x00
0x00
“00”
0x30, 0x30
Error Check (CRC/LRC)
-
0xD9, 0x5C
“E4”
0x45, 0x34
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x05
0x05
“05”
0x30, 0x35
Output Address Hi
0x10
0x10
“10”
0x31, 0x30
Output Address Lo
0x01
0x01
“01”
0x30, 0x31
Output Value Hi
0xFF
0xFF
“FF”
0x46, 0x46
Output Value Lo
0x00
0x00
“00”
0x30, 0x30
Error Check (CRC/LRC)
-
0xD9, 0x5C
“E4”
0x45, 0x34
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.5. 5 (0x05) Write Single Coil
This function code is used to write a single output to either ON or OFF in a remote device. The requested ON/OFF
state is specified by a constant in the request data field. A value of FF 00 hex requests the output to be ON. A value
of 00 00 requests it to be OFF. All other values are illegal and will not affect the output.
• Request
• Response
- Output bit of address 0x1001 turns ON.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
65MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x06
0x06
“06”
0x30, 0x36
Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Hi
0x11
0x11
“11”
0x31, 0x31
Quantity of Outputs Lo
0x22
0x22
“22”
0x32, 0x32
Error Check (CRC/LRC)
-
0x07, 0x85
“B8”
0x42, 0x38
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x06
0x06
“06”
0x30, 0x36
Output Address Hi
0x08
0x08
“08”
0x31, 0x38
Output Address Lo
0x00
0x00
“00”
0x30, 0x30
Output Value Hi
0x11
0x11
“11”
0x31, 0x31
Output Value Lo
0x22
0x22
“22”
0x32, 0x32
Error Check (CRC/LRC)
-
0x07, 0x85
“B8”
0x42, 0x38
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.6. 6 (0x06) Write Single Register
This function code is used to write a single holding register in a remote device. Therefore register numbered 1 is
addressed as 0. The normal response is an echo of the request, returned after the register contents have been
written.
• Request
• Response
- In case of address 0x0800 outputs register value: 0x0000 changes to 0x1122.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
66MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x08
0x08
“08”
0x30, 0x38
Sub-Function Hi
0x00
0x00
“00”
0x30, 0x30
Sub-Function Lo
0x00
0x00
“00”
0x30, 0x30
Data Hi
0x11
0x11
“11”
0x31, 0x31
Data Lo
0x22
0x22
“22”
0x32, 0x32
Error Check (CRC/LRC)
-
0x6C, 0x24
“BE”
0x42, 0x45
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x08
0x08
“08”
0x30, 0x38
Sub-Function Hi
0x00
0x00
“00”
0x30, 0x30
Sub-Function Lo
0x00
0x00
“00”
0x30, 0x30
Data Hi
0x11
0x11
“11”
0x31, 0x31
Data Lo
0x22
0x22
“22”
0x32, 0x32
Error Check (CRC/LRC)
-
0x6C, 0x24
“BE”
0x42, 0x45
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.7. 8 (0x08) Diagnostics
MODBUS function code 08 provides a series of tests for checking the communication system between a client
(Master) device and a server (Slave), or for checking various internal error conditions within a server.
The function uses a two–byte sub-function code field in the query to define the type of test to be performed. The
server echoes both the function code and sub-function code in a normal response. Some of the diagnostics cause
data to be returned from the remote device in the data field of a normal response.
• Request
• Response
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
67MODBUS Programmable I/O NA-9379FnIO S-Series
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x0000(0)
Any
Echo Request Data
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x0001(1)
0x0000, 0xFF00
Echo Request Data
Reset
0x0001(1)
0x55AA
Echo Request Data
Reset with Factory Default*
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000A(10)
0x0000
Echo Request Data
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000B(11)
0x0000
Total Message Count
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000C(12)
0x0000
CRC Error Count
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000D(13)
0x0000
Exception Error Count
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000E(14)
0x0000
Slave Message Count
Sub-function 0x0000(0) Return Query Data
The data passed in the request data field is to be returned (looped back) in the response.
The entire response message should be identical to the request.
The remote device could be initialized and restarted, and all of its communications event counters are cleared.
Especially, data field 0x55AA makes the remote device to restart with factory default setup of EEPROM.
*All expansion slot configuration parameters are cleared.
Sub-function 0x000A(10) Clear Counters and Diagnostic Register
The goal is to clear all counters and the diagnostic register. Counters are also cleared upon power–up.
Sub-function 0x000B(11) Return Bus Message Count
The response data field returns the quantity of messages that the remote device has detected on the
communications system since its last restart, clear counters operation, or power–up.
Sub-function 0x000C(12) Return Bus Communication Error Count
The response data field returns the quantity of CRC errors encountered by the remote device since its last restart,
clear counters operation, or power–up.
Sub-function 0x000D(13) Return Bus Exception Error Count
The response data field returns the quantity of MODBUS exception responses returned by the remote device since
its last restart, clear counters operation, or power–up.
Exception responses are described and listed in section 6.2.11.
The response data field returns the quantity of messages addressed to the remote device, or broadcast, that the
remote device has processed since its last restart, clear counters operation, or power–up.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
68MODBUS Programmable I/O NA-9379FnIO S-Series
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x000F(15)
0x0000
Slave No Response Count
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x0064(100)
0x0000
MODBUS,
Extension module Status
Same as status 1word
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x0065(101)
0x0000
Watchdog Error Count
Sub-function
Data Field (Request)
Data Field (Response)
Description
0x0066(102)
0x0000
Echo Request Data
Ready output,
Automatically turns
Normal output
0x0066(102)
0x0001, 0x0002, 0x0003
Echo Request Data
Clear output
0x0066(102)
0x0004
Echo Request Data
Normal output
0x0066(102)
0x0005, 0x0006, 0x0007
Echo Request Data
Fault output
Sub-function 0x000F(15) Return Slave No Response Count
The response data field returns the quantity of messages addressed to the remote device for which it has returned no
response (neither a normal response nor an exception response), since its last restart, clear counters operation, or power–up.
Sub-function 0x0064(100) Return Slave MODBUS, Extension module Status
The response data field returns the status of MODBUS and Extension module addressed to the remote device.
This status values are identical with status 1word of input process image. Refer to 5.3.1.
The response data field returns the quantity of watchdog error addressed to the remote device since its last restart,
clear counters operation, or power–up.
Sub-function 0x0066(102) Change Slave IO Output Status
The sub-function with data fields is to clear watchdog counter and change IO output status. This may be used to simulate
Clear output and fault output.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
69MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x0F
0x0F
“0F”
0x30, 0x46
Starting Address Hi
0x10
0x10
“10”
0x31, 0x30
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Lo
0x0A
0x0A
“0A”
0x30, 0x41
Byte Count
0x02
0x02
“02”
0x30, 0x32
Output Value #0
0x55
0x55
“55”
0x35, 0x35
Output Value #1
0x01
0x01
“01”
0x30, 0x31
Error Check (CRC/LRC)
-
0x21, 0XC9
“78”
0x37, 0x38
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x0F
0x0F
“0F”
0x30, 0x46
Starting Address Hi
0x10
0x10
“10”
0x31, 0x30
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Lo
0x0A
0x0A
“0A”
0x30, 0x41
Error Check (CRC/LRC)
-
0xD1, 0x6A
“D0”
0x44, 0x30
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.8. 15 (0x0F) Write Multiple Coils
This function code is used to force each coil in a sequence of coils to either ON or OFF in a remote device. The
Request PDU specifies the coil references to be forced. Coils are addressed starting at zero. A logical '1' in a bit
position of the field requests the corresponding output to be ON. A logical '0' requests it to be OFF.
The normal response returns the function code, starting address, and quantity of coils forced.
• Request
• Response
- In case of address 0x1015~0x1000 output bit value: 00000000_00000000 changes to 00000001_01010101.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
70MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x0F
0x0F
“0F”
0x30, 0x46
Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Registers Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Registers Lo
0x02
0x02
“02”
0x30, 0x32
Byte Count
0x04
0x04
“04”
0x30, 0x34
Register Value #0 Hi
0x11
0x11
“11”
0x31, 0x31
Register Value #0 Lo
0x22
0x22
“22”
0x32, 0x32
Register Value #1 Hi
0x33
0x33
“33”
0x33, 0x33
Register Value #1 Lo
0x44
0x44
“44”
0x34, 0x34
Error Check (CRC/LRC)
-
0x3B, 0x12
“31”
0x33, 0x31
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x0F
0x0F
“0F”
0x30, 0x46
Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Outputs Lo
0x02
0x02
“02”
0x30, 0x32
Error Check (CRC/LRC)
-
0x43, 0xCE
“DF”
0x44, 0x46
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.9. 16 (0x10) Write Multiple Registers
This function code is used to write a block of contiguous registers (1 to approx. 120 registers) in a remote device.
The requested written values are specified in the request data field. Data is packed as two bytes per register.
The normal response returns the function code, starting address, and quantity of registers written.
• Request
• Response
- In case of address 0x0800, 0x0801 output register value: 0x0000, 0x0000 changes to 0x1122, 0x3344.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
71MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x17
0x17
“17”
0x31, 0x37
Read Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Read Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Read Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Read Lo
0x02
0x02
“02”
0x30, 0x32
Write Starting Address Hi
0x08
0x08
“08”
0x30, 0x38
Write Starting Address Lo
0x00
0x00
“00”
0x30, 0x30
Quantity of Write Hi
0x00
0x00
“00”
0x30, 0x30
Quantity of Write Lo
0x02
0x02
“02”
0x30, 0x32
Byte Count
0x04
0x04
“04”
0x30, 0x34
Write Reg. Value #0 Hi
0x11
0x11
“11”
0x31, 0x31
Write Reg. Value #0 Lo
0x22
0x22
“22”
0x32, 0x32
Write Reg. Value #1 Hi
0x33
0x33
“33”
0x33, 0x33
Write Reg. Value #1 Lo
0x44
0x44
“44”
0x34, 0x34
Error Check (CRC/LRC)
-
0x88, 0x3F
“20”
0x32, 0x30
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x17
0x17
“17”
0x31, 0x37
Byte Count
0x04
0x04
“04”
0x30, 0x34
Write Reg. Value #0 Hi
0x11
0x11
“11”
0x31, 0x31
Write Reg. Value #0 Lo
0x22
0x22
“22”
0x32, 0x32
Write Reg. Value #1 Hi
0x33
0x33
“33”
0x33, 0x33
Write Reg. Value #1 Lo
0x44
0x44
“44”
0x34, 0x34
Error Check (CRC/LRC)
-
0x2E, 0xD2
“34”
0x33, 0x34
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
A.3.10. 23 (0x17) Read/Write Multiple Registers
This function code performs a combination of one read operation and one write operation in a single MODBUS
transaction. The write operation is performed before the read. The request specifies the starting address and
number of holding registers to be read as well as the starting address, number of holding registers, and the data to
be written. The byte count specifies the number of bytes to follow in the write data field.
The normal response contains the data from the group of registers that were read. The byte count field specifies the
quantity of bytes to follow in the read data field.
• Request
• Response
- In case of address 0x0800, 0x0801 output register value: 0x0000, 0x0000 changes to 0x1122, 0x3344.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
72MODBUS Programmable I/O NA-9379FnIO S-Series
Address
IEC Address
Contents
0x0000~0x027F
%IW0~%IW639
640 word Input and Internal memory (Area is write-protected)
0x0280~0x07FF
-
Illegal data address
0x0800~0x0A7F
%QW0~%QW639
640 word Output and Internal memory (Area is write-enabled)
0x0A80~0x0FFF
-
Illegal data address
0x1000~0x1FFF
-
Special Function Register (PIO Information)
0x2000~0x2FFF
-
Special Function Register (Slot Information)
0x4000~0x427F
%MW0~%MW639
640 word Internal memory (Area is write-enabled)
Address
Access
Type, Size
Description
0x1000(4096)
Read
1 word
Vendor ID = 0x02E5 (741), Crevis. Co., Ltd.
0x1001(4097)
Read
1 word
Device type = 0x000C, Network Adapter
0x1002(4098)
Read
1 word
Product code. 0x2000
0x1003(4099)
Read
1 word
Firmware revision, if 0x0101, revision 1.01
0x1004(4100)
Read
2 words
Product unique serial number
0x1005(4101)
Read
String up to
34bytes
Product name string
First 1word is length of valid character string
Example) response as following
“00 12 4E 41 39 33 37 39 5F 50 49 4F 5F 41 64 61 70 74 65 72 00 00 00 00 00 00 00 00 00
00 00 00 00 00”
Valid character size = 0x0017 =29 characters
“NA-9379_PIO_Adapter”
0x1006(4102)
Read
1 word
Sum check of EEPROM
0x1010(4112)
Read
2 words
Firmware release date
0x1011(4113)
Read
2 words
Product manufacturing inspection date
0x1012(4114)
Read
String up
to 34bytes
Vendor name string
First 1word is length of valid character string.
The special register map can be accessed by function code 3, 4, 6 and 16. Also the special register map must be
accessed by read/write of every each address (one address).
A.4.1. Adapter Register Mapping
A.4.2. Adapter Identification Special Register (0x1000, 4096)
* String Type consists of valid string length (first 1word) and array of characters.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
73MODBUS Programmable I/O NA-9379FnIO S-Series
Address
Access
Type, Size
Description
0x1020(4128)
Read/Write
1 word
Watchdog time value 16bit unsigned.
The time value is represented by multiples of 100msec.
The 0 (watchdog timeout disabled) is default value.
A changing of watchdog time value resets watchdog error and
counter.
0x1021(4129)
Read
1 word
Watchdog timer remain value
This value is decreased every 100msec
0x1022(4130)
Read
1 word
Watchdog error counter, it is cleared by writing address
0x1020
0x1023(4131)
Read/Write
1 word
Enable/disable auto recovery Watchdog error when receiving
new frame.
0:Disable, 1:Enable(default). Its value is stored in EEPROM.
0x1028(4136)
Read
4 words
I/O update time, Expansion Module Process time, CoDeSys
update time, CoDeSys Process Time. (1usec unit)
A.4.3. Adapter Watchdog Time, other Time Special Register (0x1020, 4128)
A watchdog timer can be configured for timeout periods up to 65535(1unit=100msec). The Watchdog timer will
timeout (timer decreased, reached 0) if MODBUS operation to the slave node does not occur over the configured
watchdog value, then the slave adapter forces that slot output value is automatically set to user-configured fault
actions and values.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
74MODBUS Programmable I/O NA-9379FnIO S-Series
Address
Access
Type, Size
Description
0x1100(4352)
Read/Write
1 word
Reserved.
0x1101(4353)
Read
1 word
Reserved.
0x1102(4354)
Read
1 word
Start address of input image word register. =0x0000
0x1103(4355)
Read
1 word
Start address of output image word register. =0x0800
0x1104(4356)
Read
1 word
Size of input image word register.
0x1105(4357)
Read
1 word
Size of output image word register.
0x1106(4358)
Read
1 word
Start address of input image bit. = 0x0000
0x1107(4359)
Read
1 word
Start address of output image bit. =0x1000
0x1108(4360)
Read
1 word
Size of input image bit.
0x1109(4361)
Read
1 word
Size of output image bit.
0x110D(4365)
Read/Write
1word
Enable/Disable Auto Reboot when expansion module,
0:Disable(Default)
0x110E(4366)
Read
Up to 33 word
Expansion slot’s ST-number including NA
First 1word is adapter’s number, if NA-9379, then 0x9379
0x1110(4368)
Read
1 word
Number of expansion slot
0x1111(4369)
Read
1 word
Number of active slot
0x1112(4370)
Read
1 word
Number of inactive slot
0x1113(4371)
Read
Up to
33 word
Expansion slot Module Id. Refer to Appendix B.1 Product List.
First 1word is adapter’s module id.
0x1114(4372)*
Read/Write
1 word
Input process image mode. The default value is 2.
Valid value range is from 0 to 3.
0x1115(4373)*
Read/Write
1 word
Output process image mode. The default value is 0.
Valid value range is from 0 to 1.
0x1116(4374)**
Read/Write
2 words
Inactive slot list, The corresponding bit represents slot position.
0: Active slot, 1: Inactive slot.
Ex) if value is 0x0001, 0x8000, then slot#1,#32 are inactive slots
0x1117(4375)
Read
2 words
Live slot list. , The corresponding bit represents slot position.
1: live slot, 0: not live slot
0x1118(4376)
Read
2 words
Alarm slot list. The corresponding bit represents slot position.
1: Alarm slot, 0: Normal slot
0x1119(4377)
Read
1 word
Hi byte is MODBUS status, low byte is expansion module status.
It is identical with address 0x1040.
0x111A(4378)
Write
1 word
Reserved. Adapter Scan command.
0x111B(4379)
Read/Write
1 word
Reserved. IO State machine.
0x111C(4380)
Read
2 words
Reserved. Runtime fault code.
0x111D(4381)
Read
1 word
Adapter Revision. If 0x013C, Revision is 1.60
0x111E(4382)
Read
1 word
Reserved. Adapter IO identification vendor code.
0x111F(4383)
Read
5 word
LED Display Value and Status Code
A.4.4. Adapter Information Special Register (0x1100, 4352)
* After the system is reset, the new “Set Value” action is applied.
* If the slot location is changed, set default value automatically (all expansion slots are live).
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
Read/write Configuration parameter data, up to 8byte. ***
+ 0x12(+18)
Read
1word
Size of memory byte.
+ 0x13(+19)**
Read/Write
n word
Read/write Memory data. Offset of memory is fixed with 0
+ 0x14(+20)**
Read/Write
n word
Read/write Memory data. First 2byte of write data is memory
offset.
+ 0x15(+21)
Read
2word
Product code Refer to Appendix B.1 Product List.
+ 0x16(+22)
Read
2word
Catalog number. Refer to Appendix B.1 Product List.
+ 0x17(+23)
Read
1word
Firmware Revision
+ 0x18(+24)
Read
1word
Expansion Module Revision
+ 0x1A(+26)
Read/Write
n word
Reserved. Read/write expansion class access. (vendor only)
+ 0x1B(+27)
Read/Write
n word
Reserved. Read/write maintenance data access. (vendor only)
* After the system is reset, the new “Set Value” action is applied.
** Nothing of output, input, and memory or configuration parameter corresponding slot returns Exception 02.
*** Slot Configuration parameter saved by internal EEPROM during power cycle until slot position changed.
*** All of output modules and special modules have the slot configuration parameter data. Refer to Document.
Input/output Data Type: 0 0: No I/O Data / 0 1: Byte Data / 1 0: Word Data / 1 1: Bit Data
Input/output Data Length: 0 0 0 0 0 0 0: 0 Bit/Byte/Word / 0 0 0 0 0 0 1: 1 Bit/Byte/Word / 0 0 0 0 0 1 0: 2 Bit/Byte/Word /0 0 0 0 0 1 1: 3 Bit/Byte/Word / 0 0 0 0 0 1 1: 3 Bit/Byte/Word
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
78MODBUS Programmable I/O NA-9379FnIO S-Series
Addr.
#15
#14
#13
#12
#11
#10
#9
#8
#7
#6
#5
#4
#3
#2
#1
#0
0x0000
EW 0 0 0 0 0 0 0 FP
Internal protocol Status
0x0001
Discrete In 8pts (Slot#2)
Empty, Always 0
Discrete In 4pts (Slot#1)
0x0002
Analog Input Ch0 high byte (Slot#3)
Analog Input Ch0 low byte (Slot#3)
0x0003
Analog Input Ch1 high byte (Slot#3)
Analog Input Ch1 low byte (Slot#3)
0x0004
Discrete In high 8pts (Slot#4)
Discrete In low 8pts (Slot#4)
0x0005
Discrete In 8pts (Slot#6)
Empty, Always 0
Discrete In 4pts (Slot#5)
0x0006
Analog Input Ch0 low byte (Slot#8)
Empty, Always 0
Discrete In 4pts (Slot#7)
0x0007
Analog Input Ch1 low byte (Slot#8)
Analog Input Ch0 high byte (Slot#8)
0x0008
Discrete In low 8pts (Slot#9)
Analog Input Ch1 high byte (Slot#8)
0x0009
Empty, Always 0
Discrete In 4pts (Slot#10)
Discrete In high 8pts (Slot#9)
Slot Address
Module Description
#0
MODBUS Adapter
#1
4-discrete input
#2
8-discrete input
#3
2-analog input
#4
16-discrete input
#5
4-discrete input
#6
8-discrete input
#7
4-discrete input
#8
2-analog input
#9
16-discrete input
#10
4-discrete input
Status
(1word)
A.5 Example
A.5.1. Example of Input Process Image(Input Register) Map
Input image data depends on slot position and expansion slot data type. Input process image data is only ordered
by expansion slot position when input image mode is uncompressed (mode 0, 2). But, when input image mode is
compressed (mode 1, 3), input process image data is ordered by expansion slot position and slot data type.
Input process image mode can be set by special register 0x1114(4372). Refer to 6.3.3.
• Input Process Image Mode#2 (Uncompressed Input Processing Data without Status), default input image
• Input Process Image Mode#3 (Compressed Input Processing Data without Status)
* S-Series uses the byte-oriented register mapping.
* Size of input image bit is size of input image register *16.
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
80MODBUS Programmable I/O NA-9379FnIO S-Series
Addr.
#15
#14
#13
#12
#11
#10
#9
#8
#7
#6
#5
#4
#3
#2
#1
#0
0x0800
Discrete out 8pts (Slot#2)
Empty, Don’t care
Discrete out 4pts (Slot#1)
0x0801
Analog out Ch0 high byte (Slot#3)
Analog out Ch0 low byte (Slot#3)
0x0802
Analog out Ch1 high byte (Slot#3)
Analog out Ch1 low byte (Slot#3)
0x0803
Discrete out high 8pts (Slot#4)
Discrete out low 8pts (Slot#4)
0x0804
Discrete out 8pts (Slot#6)
Empty, Don’t care
Discrete out 4pts (Slot#5)
0x0805
Empty, Don’t care
Discrete
out 2pts
(Slot#8)
Empty, Don’t care
Discrete
out 2pts
(Slot#7)
0x0806
Analog out Ch0 high byte (Slot#9)
Analog out Ch0 low byte (Slot#9)
0x0807
Analog out Ch1 high byte (Slot#9)
Analog out Ch1 low byte (Slot#9)
0x0808
Discrete out high 8pts (Slot#10)
Discrete out low 8pts (Slot#10)
0x0809
Empty, Don’t care
Empty, Don’t care
Discrete out 4pts
(Slot#11)
Slot Address
Module Description
#0
MODBUS Adapter
#1
4-discrete output
#2
8-discrete output
#3
2-analog output
#4
16-discrete output
#5
4-discrete output
#6
8-discrete output
#7
2-relay output
#8
2-relay output
#9
2-analog output
#10
16-discrete output
#11
4-discrete output
Input Assembly Priority :
1) Analog Input Data (Word type)
2) 8 or 16 points Discrete Input Data (Byte type)
3) 4 points Input Data (Bit type)
4) 2 points Input Data (Bit type)
A.5.2. Example of Output Process Image(Output Register) Map
Output image data depends on slot position and expansion slot data type. Output process image data is only
ordered by expansion slot position when output image mode is uncompressed (mode 0). But, when output image
mode is compressed (mode 1), output process image data is ordered by expansion slot position and slot data type.
Output process image mode can be set by special register 0x1115(4373). Refer to 6.3.3.
• For example slot configuration
• Output Process Image Mode#0 (Uncompressed Output
Processing Data), default output image
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
81MODBUS Programmable I/O NA-9379FnIO S-Series
Addr.
#15
#14
#13
#12
#11
#10
#9
#8
#7
#6
#5
#4
#3
#2
#1
#0
0x0800
Analog out Ch0 high byte (Slot#3)
Analog out Ch0 low byte (Slot#3)
0x0801
Analog out Ch1 high byte (Slot#3)
Analog out Ch1 low byte (Slot#3)
0x0802
Analog out Ch0 high byte (Slot#9)
Analog out Ch0 low byte (Slot#9)
0x0803
Analog out Ch1 high byte (Slot#9)
Analog out Ch1 low byte (Slot#9)
0x0804
Discrete out low 8pts (Slot#4)
Discrete out 8pts (Slot#2)
0x0805
Discrete out 8pts (Slot#6)
Discrete out high 8pts (Slot#4)
0x0806
Discrete out high 8pts (Slot#10)
Discrete out low 8pts (Slot#10)
0x0807
Discrete
Out 2pts
(Slot#8)
Discrete
Out 2pts
(Slot#7)
Discrete out 4pts
(Slot#11)
Discrete out 4pts (Slot#5)
Discrete out 4pts (Slot#1)
• Output Process Image Mode#1 (Compressed Output Processing Data)
* S-Series uses the byte-oriented register mapping.
* Size of input image bit is size of input image register *16.
Output Assembly Priority :
1) Analog Output Data (Word type)
2) 8 or 16 points Discrete Output Data (Byte type)
3) 4 points Output Data (Bit type)
4) 2 points Output Data (Bit type)
Copyright(C) CREVIS Co.,Ltd Support +82-31-899-4599 URL : www.crevis.co.kr
82MODBUS Programmable I/O NA-9379FnIO S-Series
Field name
Example
RTU
ASCII
ASCII (bus line)
Start of Frame
-
t1-t2-t3
“,”
0x3A
Slave Address
0x07
0x07
“07”
0x30, 0x37
Function Code
0x81
0x81
“81”
0x38, 0x31
Exception Code
0x02
0x02
“02”
0x30, 0x32
Error Check (CRC/LRC)
-
0x22, 0xC0
“76”
0x37, 0x36
End of Frame
-
t1-t2-t3
CR, LF
0x0D, 0xA
Exception
Code
Name
Description
01
Illegal Function
The function code received in the query is not an allowable action
for the server (or slave).
02
Illegal Data Address
The data address received in the query is not an allowable address
for the server (or slave).
03
Illegal Data Value
A value contained in the query data field is not an allowable value
for server (or slave).
04
Slave Device Failure
An unrecoverable error occurred while the server (or slave) was
attempting to perform the requested action.
05
Acknowledge
The server (or slave) has accepted the request and is processing it,
but a long duration of time will be required to do so.
06
Slave Device Busy
Specialized use in conjunction with programming commands.
The server (or slave) is engaged in processing a long–duration
program command. The client (or master) should retransmit the
message later when the server (or slave) is free.
08
Memory Parity Error
The server (or slave) attempted to read record file, but detected a
parity error in the memory. The client (or master) can retry the
request, but service may be required on the server (or slave)
device.
0A
Gateway Path Unavailable
Specialized use in conjunction with gateways, indicates that the
gateway was unable to allocate an internal communication path
from the input port to the output port for processing the request.
A.6 Error Response
In an exception response, the server sets the MSB of the function code to 1. This makes the function code value in
an exception response exactly 80 hexadecimal higher than the value would be for a normal response.