Danfoss RS 485 RTU Design guide

Design guide
DATA COMMUNICATION MODBUS RS 485 RTU
For product type - EKD / EIM controllers
This User guide document provides general information on the setup of Modbus RS-485 networks and explains how to congure the communication between EKD/EIM and a system controller, using the Modbus RTU.
Features • Simplicity
• Standard Ethernet
• Open protocol
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 1
Design guide | Data Communication Modbus RS485 RTU
Part 1 - Hardware network specication
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Denitions and abbreviations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Wiring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
RS-485 specic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Repeater . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Topology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Cable connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Termination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Conductors in a daisy chain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Ground connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Part 2 - Software specication and conguration
Introduction of RS-485 Communication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Modbus RTU message. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Modbus RTU message structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
How to access parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
RS485 bus function codes overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
EKD examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
EIM examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Appendix 1 EIM Modbus conversion table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Appendix 2 EKD Modbus table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Appendix 3 Modbus exception code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Appendix 4 Modbus tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 2
Design guide | Data Communication Modbus RS485 RTU
Introduction
References
Denitions and abbreviations
Making a network means to connect devices together with a communication bus. But to make reliable and high performance networks strict rules must be followed.
Modbus specications, Modbus.org EIA-485 RS-485 eldbus specication
RTU Remote Terminal Unit SW Software HW Hardware AWG American Wire Gauge EKE / EIM / EKD Superheat Controller/driver Parameter The parameter number indicates the number of a given parameter. Value Indicates the factory settings. Typ e Group. Group (number) indicates the group the relevant parameter
belongs to. The group number is only of importance for presentation in AKM PC software. PNU Short for Parameter NUmber. In Modbus terminology it corresponds to the register number which is also often referred to as the oset. The PNU numbers can have values in the range from 1 to 65535. The corresponding Modbus address is found by subtracting 1 from the PNU number. For instance PNU number 117 would correspond to Modbus address 116.”
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 3
84N404.10
Design guide | Data Communication Modbus RS485 RTU
Wiring
Wiring characteristics
Wiring types
Recommendations (Source Modbus.org)
The wires should have the following characteristics:
• Characteristic impedance: 120 Ohm +/- 10%;
• Specic resistance depending on network length.
• Cable must be with Screen if the bus cable exceeds 3m.
• The cable is connected from controller to controller and no branches are allowed on the cable
• Each shield must be grounded at one side only.
Two types of wires can be used based on required ruggedness:
1. Twisted pair with ground: short leads, no power lines in proximity.
2. Twisted pair + ground and shield: long leads, disturbed environment.
When choosing a transmission line for RS-485, it is necessary to examine the required distance of the cable and the data rate of the system. An RS485-Modbus must use a balanced pair (for D+-D-) and a third wire (for the Common/Gnd). For RS485-Modbus, Wire Gauge must be chosen suciently wide to permit the maximum length (1000 m ). AWG 22 is always sucient for the Modbus Data. Category 5 cables may operate for RS485-Modbus, to a maximum length of 600m. For the balanced pairs used in an RS485-system, a Characteristic Impedance with a value higher than 100 Ohms may be preferred, especially for 19200 and higher baud rates.
Use one twisted pair of conductors for connecting the dierential signals and use another conductor (for example a second twisted pair) for connecting the ground.
Note!
Modbus
D+ (A+) D– (B–)
Modbus connections
EKE EKD EIM
D+ A+ TxD+
D- B- TxD-
Danfoss
Fig. 1 Connection example
GND
Gnd Gnd
1
) Gnd has been omitted from EIM.
Connection of a twisted cable in a 2-wire Modbus system may cause damages.
1
)
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 4
Danfoss
84B3210.10
Repeater
Design guide | Data Communication Modbus RS485 RTU
RS-485 specic
RS-485: Controllers
Repeater
The RS-485 consists of three wires:
• RS-485-A (D+);
• RS-485-B (D-);
• GND. The two wires RS-485-A (D+) and RS-485-B (D-) propagate a dierential communication signal. In addition there is the ground wire for the common mode voltage reference. The recommended maximum Modbus cable length between the EKE(/EKD/EIM) and the system controller should not exceed 1000 meters (3300 feet).
Wire length
Length (m) Max. baudrate Min. Wire size Suggested types
1000 125 K AWG22 Belden 3106A / 3107A
The maximum number of controllers that can be connected to a Modbus line is 120. One repearter must be added for every 32 controllers. If the data communication cable runs through an electrically noisy environment which impairs the data signal, one or more repeaters must be added to stabilize the signal.
A repeater has no address. A repeater from the company "Phoenix" can be used: Danfoss code no. = 084B2240 (type AKA 222).
Master
Modbus
Master
Modbus
Slaves
max. 1000 m
Slaves Slaves
Danfoss
84B3210.10
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 5
Min 10-15 cm
Danfoss
84B3206.10
Field BUSField BUS
Danfoss
84B3205.10
Field BUS
Stub
Danfoss
84B3203.10
Design guide | Data Communication Modbus RS485 RTU
Topology
Standard topology
Recommendations
The controller should be connected according to the bus topology. That means that the communica­tion cable is wired from one controller to the next without branches.
Three conductors
T
001
002
T
n
Three conductors + shiels
T
001
Legend
Shield
Communication cable, 120 Ω impedance
T
120 Ω termination
002
T
n
Danfoss
84B3202.10
Avoid making stubs on the line. If stubs are present in the network they should be kept as short as possible (<0.3 m at 1 Mbit; <3 m at 50 kbit).
Fig Fieldbus with ‘’STUB” 01
Fig Star topology
Do not use a ‘STAR topology’
- 0.0.0. - 0.0.0.
Fig Fieldbus with ‘’STUB” 02
Fig Fieldbus wire
Do not route the eldbus wires close to power lines or wires leading to heavy loads
Danfoss
84B3204.10
© Danfoss | DCS (sw) | 2015.10
DKRCC.PS.R00.A1.02 | 520H10468 | 6
Loading...
+ 12 hidden pages