Professional Documents
Culture Documents
0
Modbus RTU and Modbus TCP
Screw- and piston compressor
Using Modbus, a master (eg PC) and many devices (eg temperature and humidity measurement)
could be connected. The focus control 2.0 supports as well Modbus RTU over serial line (EIA-485
(formerly RS-485) in halfduplex specification as Modbus TCP via Ethernet interface.
Each bus device must have a unique address. Address 0 is reserved for broadcasting. Each device is
allowed to send messages over the bus. In general, however, this is initiated by the master and an
addressed slave responds.
The description of the various specifications and protocols are available here: http://modbus.org/.
Settings
Modbus RTU
All adjustments to operate the serial interface must be made in the parameters P2.50 to P2.55. Here,
the following options are supported:
Parameter
Name Options
Base module RS485 module
P2.50 P2.53 Device address (1/2) Master: The device acts as Master
1…248: device address (Slave)
P2.51 P2.54 Bit rate (1/2) 2400
4800
9600
19200
38400
57600
115200
P2.52 P2.55 Protocol frame (1/2) 8 Even 1
8 None 1
8 None 2
8 Even 2
8 Odd 1
8 Odd 2
All Parameters could be modified with Login-Level ‘User’. Please refer to the manual of focus
control 2.0.
Modbus TCP
Function codes
Following functions are support by focus control 2.0:
Code Function
04 (04hex) Read Input Registers
06 (06hex) Write Single Register
16 (10hex) Write Multiple Register
Data types
All data are transferred in 16bit registers. According to Modbus specification, the high byte is always
transferred first in a register followed by the low byte (Big Endian). 32bit values are transmitted in 2
consecutive registers. Since there is no fixed rule for this, it should be pointed out here that the
transmission also takes place according to this rule.
To ensure data consistency, 32bit values must always be read out in ascending order.
However, reading in two successive protocols is possible.
Addressing
Normally, the data is subdivided into reference groups in the Modbus protocol:
Group Reference
Coils 0xxxx
Discrete Inputs 1xxxx
Input Register 3xxxx
Holding Register 4xxxx
Specifically, the numbering of the registers is starting with 1, but starting with 0 in the telegram.
1
Unless otherwise indicated, all pressure values in [ /10 bar] and all temperatures in [°C]
Register
Type Description
address
1 UINT16 Identification
12883 (3253hex) = focus control 2.0 screw compressor
12880 (3250hex) = focus control 2.0 piston compressor
2 reserved
3 UINT16 Version No. (major)
4 UINT16 Version No. (minor)
If this compressor acts as master, bit 4…7 have the following meaning:
Bit 4: load request compressor ‘A’
Bit 5: load request compressor ‘B’
Bit 6: load request compressor ‘C’
Bit 7: load request compressor ‘D’
Register
Type Description
address
1 WORD Bit 0: compressor ON
Bit 1: compressor OFF
Bit 2: Load request
Bit 3: pressure range
Bit 4: confirmation of malfunction/service message
Bit 5: reserved
Bit 6: Connection check
Bit 7…15: reserved
2 INT16 Timer channel select
0…49: select timer channel (1…50) for reading (see Input Register 55…58)
Elements marked as not used must contain 0, because those elements are used as reserve for
upgrades.
When remote ON/OFF is configured and active, the compressor could not be switched on/off
using the push buttons ‚I‘ respectively ‚O‘.
If On/Off function is configured in mode ‘Remote (contact AND bus/Ethernet)’, the signal is
ANDed with an external contact.
If a key switch is installed, the position decides whether the compressor could be accessed by
remote or local.
Load request
Using bit 2 the load request of the compressor could be controlled. If bit 2 is set, the compressor runs
in load mode when the controller has detected a load request. Load request controlled via bus is only
possible when the following conditions are fulfilled:
If the connection check bit is not served, the request is controlled by the external contact,
respectively by the internal pressure control when the terminal is jumpered.
Pressure range
If bit 3 is set the controller switches to pressure range 2 (defined by P2.14 / P2.15)
If the connection check bit is not served pressure range 1 (P2.12 / P2.13) will be activated.
Changing pressure range is only available when release is also made via bus.
Confirmation
Bit 4 is used to confirm malfunction, warning and service messages. If a message is displayed, this
message is confirmed on a rising edge of this bit
To ensure that the controller detects condition changes, the time between changes should be in
a timeframe less than 4 second and greater than 0.2 seconds