E119-P
Page 64 FW_E119-P_M_v0301-02_EN
APPENDIX C - MODBUS COMMUNICATION
C.1 INTRODUCTION
The product is fitted with the Modbus communication protocol and can be equipped with various
physical interfaces like RS485 and RS232 (please see device datasheet for available options).
The tables below show the various variables that can be accessed through the communication.
Currently, the function codes supported are:
● function code 3 “Read Holding Registers” (4x references)
● function code 16 “Preset Multiple Registers” (4x references)
The tables show the Modbus PDU addresses in a decimal format, followed by its hexadecimal
representation (0x0000). When the PLC address range is required (4x references are typically used
by PLCs), please use the holding register addresses.
Variables consisting of multiple registers
Several variables in the system are too big to fit in a single register and are spanned over multiple
registers. Most Modbus masters support variables that span 2 or 4 registers in integer and floating
point format. If your Modbus master does not support any of the supplied formats, select an integer
based variable and calculate the corresponding value manually, as shown in the following example:
Example
1. Assume variable accumulated total spans 3 registers with addresses 560, 561 and 562.
2. When a transmission is done, register 560 (the MSW - most significant word) arrives first,
followed by register 561 in the middle and register 562 at the end (the LSW - least significant
word). The following figure shows this and how to calculate the value.
MSW LSW
ACCUMULATED TOTAL
REGISTER 560 REGISTER 561 REGISTER 56200001
0x0001
45236
0xB0B4
34756
0x87C4
Value: [d]
[h]
Value: [d]
[h]
Value: [d]
[h]
MSB LSB
15 15 15
000
47 31 15
01632
ACCUMULATED TOTAL:
Calculation [d]:
Calculation [h]:
[register 560 * 2 ] + [register 561 * 2 ] + [register 562*1]
[00001 * 4294967296] + [45236 * 65536] + [34756*1] = 7259588548
0x[0001] [B0B4] [87C4] = 0x0001B0B487C4
32 16
Fig.41: Multiple register variable
Datatypes
The following datatypes are used for Modbus communication with the unit:
Data type
Number of
bytes
Number of
16 bit registers
Description
char 1 1 8 bits ASCII character
char[] array 2 chars per register array of char’s (see remarks for array length)
uint16 2 1 16 bits unsigned integer
uint32 4 2 32 bits unsigned integer
int32 4 2 32 bits signed integer
uint48 6 3 48 bits unsigned integer
uint64 8 4 64 bits unsigned integer
float32 4 2 32 bits floating point
float64 8 4 64 bits floating point
When reading and writing integer-type variables, values are transmitted without the decimal point.
For the correct representation, please see the remarks-field in the tables below.
Variables spanning multiple registers use ‘big-endian’ data representation.
For more information about using your Modbus device, please read our ’General Modbus
Communication Protocol’ and ‘Modbus Troubleshooting Guide’ available through our website or your
distributor.