Diferencia entre revisiones de «ModbusRTU-RS485/en»

De wiki.kiconex
(Página creada con «== Modbus RTU-RS485 connection ==»)
 
(Página creada con «=== Characteristics that define Modbus RTU communication === Every control that connects to a Modbus RTU network with an RS485 connector has a series of characteristics or configurations that allow it to communicate through said protocol:»)
 
(No se muestran 4 ediciones intermedias del mismo usuario)
Línea 1: Línea 1:
<span id="Conexión_Modbus_RTU-RS485"></span>
== Modbus RTU-RS485 connection ==
== Modbus RTU-RS485 connection ==
__TOC__
__TOC__


Línea 8: Línea 5:
The [https://{{SERVERNAME}}/index.php/Special:MyLanguage/Modbus-protocol '''Modbus RTU protocol'''] through RS485 connections is a standard widely used in industrial environments, since it allows the fluid and effective exchange of information over long distances. However, to avoid any possible interference and have completely stable communication, it is necessary that the buses meet a series of requirements that are detailed on this page.
The [https://{{SERVERNAME}}/index.php/Special:MyLanguage/Modbus-protocol '''Modbus RTU protocol'''] through RS485 connections is a standard widely used in industrial environments, since it allows the fluid and effective exchange of information over long distances. However, to avoid any possible interference and have completely stable communication, it is necessary that the buses meet a series of requirements that are detailed on this page.


<span id="Requisitos_de_cableado"></span>
<div class="mw-translate-fuzzy">
===Wiring requirements===
=== Wiring requirements ===
 
* Use a halogen-free 3-wire shielded cable that provides protection against interference in Modbus RTU communication.
* Use of halogen-free shielded cable that provides protection against interference in Modbus RTU communication.
* Distance of at least 20cm from power lines.
* Distance of at least 20cm with power lines.
* Respect the polarity of each RS485 connection
* Connection between devices following a daisy-chain topology, as shown in the following image:
* Connection between devices following a daisy-chain topology, as shown in the following image:
[[Archivo:SP - Esquema de un bus único siguiendo la topología daysi change.jpg|center|imagethumbnail|800x800px|Connection of RS485 equipment following a daisy-chain topology]]
[[File:Cableado tierras v2024.jpg|center|thumbnail|800x800px|Connection of RS485 devices following a daisy-chain topology]]
* Respect the polarity of each RS485 connection
* '''Common:''' if there is a connection for a common cable, a cable will come out of the terminal block (or kibox) that will go from the common to the common of the first control. It is connected to the common and from there a splice comes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
* Connection of the screen or mesh of the ground cable at the beginning of the line (kiBox) or at the end of the line, never at the intermediate nodes.
* '''+ positive:''' A cable will come out of the terminal block (or kibox, depending on whether there is a kiconex electrical panel) that will go from the positive to the positive of the first control. It is connected to the positive and from there a splice goes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
* '''- negative:''' A cable will come out of the terminal block (or kibox, depending on whether there is a kiconex electrical panel) that will go from the negative to the negative of the first control. It is connected to the negative and from there a splice goes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
* '''GND ground without kiconex electrical panel:''' the mesh (the covering of the shielded cable) will be connected to the ground of the installation. Between the controls connected in series, the shield must be connected to each other. It will 'die' in the last control.
* '''GND ground with kiconex electrical panel:''' from the GND terminal block the shield of the shielded cable is connected. The other end must be connected to the shield of the shielded cable of the next control connected in series. The shield will 'die' in the last control.
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
=== Characteristics that define Modbus RTU communication ===
=== Características que definen la comunicación Modbus RTU ===
Every control that connects to a Modbus RTU network with an RS485 connector has a series of characteristics or configurations that allow it to communicate through said protocol:
Todo control que se conecta a una red Modbus RTU con conector RS485 tiene una serie de características o configuraciones que le permiten comunicar a través de dicho protocolo:
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
* A '''unique Modbus address''' and different from the rest of the controls connected on the same line. The address value is set between 1 and 247.
* Una '''dirección Modbus única''' y diferente del resto de controles que haya conectados en la misma línea. El valor de la dirección se establece entre 1 y 247.
* A '''communication configuration''', which must be '''the same as all the controls''' connected on that line. Depending on the model and manufacturer of the control, this configuration is static or configurable through parameters. By consulting the manufacturer's manual you can verify this information. The communication configuration variables are:
* Una '''configuración de comunicación''', que debe ser '''la misma que tengan todos los controles''' conectados en esa línea. Según el modelo y el fabricante del control, esta configuración es estática o configurable a través de parámetros. C''onsultando el manual del fabricante se puede verificar esta información''. Las variables de configuración de comunicación son:
** Speed or baudrate: 9600bps, 19200bps, etc.
** Velocidad o baudrate: 9600bps, 19200bps, etc.
** Data bits: 7 or 8
** Bits de datos: 7 u 8
** Parity bits: none, even or odd
** Bits de paridad: ninguna, par o impar
**Stop bits: 1 or 2
** Bits de parada: 1 o 2
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
=== Steps in connecting RS485 lines with kiconex ===
=== Pasos en la conexión de las líneas RS485 con kiconex ===
1 - Plan how the controls will be distributed between the different RS485 ports available on the kiBox. The page about [https://{{SERVERNAME}}/index.php/Special:MyLanguage/Planning-route '''facility planning'''] explains this. It is important to take into account the [[ModbusRTU-RS485#Characteristics that define Modbus RTU communication|'''characteristics of the Modbus protocol''']] when making this plan. The following table is indicative when establishing said planning:
1 - Planificar cómo se distribuirán los controles entre los distintos puertos RS485 disponibles en el kiBox. En la página sobre [https://{{SERVERNAME}}/index.php/Special:MyLanguage/Planning-route '''planificación de la instalación'''] se explica este aspecto. Es importante tener en cuenta las [[ModbusRTU-RS485#Características que definen la comunicación Modbus RTU|'''características del protocolo Modbus''']] a la hora de realizar este plan. La siguiente tabla es orientativa a la hora de establecer dicha planificación:
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
<div class="mw-translate-fuzzy">
{| class="wikitable"
{| class="wikitable"
|+
|+
!NOMBRE DEL EQUIPO
!NAME OF THE TEAM
!PUERTO RS485
!RS485 PORT
!DIRECCIÓN MODBUS
!MODBUS ADDRESS
|-
|-
| Identificador del control
|   Control identifier
| Según modelo de kiBox, hasta 8
|   Depending on the kiBox model, up to 4
| Valores de la 1 a la 247
|   Values from 1 to 247
|}
|}
2 - Conectar tantos buses o cables apantallados como puertos RS485 se hayan planificado, cada uno de esos buses deben seguir los '''[[ModbusRTU-RS485#Requisitos de cableado|requisitos de cableado anteriores]].'''
2 - Connect as many buses or shielded cables as RS485 ports have been planned, each of these buses must follow the '''[[ModbusRTU-RS485#Wiring requirements|wiring requirements above]].'''
</div>
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
3 - '''Configure''' manually in each control the '''Modbus address''' planned in point 1.
3 - '''Configurar''' manualmente en cada control la '''dirección Modbus''' planificada en el punto 1.
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
4 - Verify that all Modbus buses have been set correctly by performing a [https://{{SERVERNAME}}/index.php/Special:MyLanguage/CheckWiring ''checking''].
4 - Verificar que todos los buses Modbus han quedado correctamente realizando una [https://{{SERVERNAME}}/index.php/Special:MyLanguage/CheckWiring '''comprobación de los mismos'''].
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
5 - Connect the buses to their respective RS485 ports on the kiBox, access [https://my.kiconex.com/ myKiconex] and begin operating the remote facility.
5 - Conectar los buses a sus respectivos puertos RS485 en el kiBox, acceder a [https://my.kiconex.com/ myKiconex] comenzar a operar la instalación en remoto.
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
=== Connection example ===
=== Ejemplo de conexión ===
The image below represents an example of a generic connection where they are connected:
En la imagen que aparece más abajo se representa un ejemplo de conexión genérica donde se conectan:
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
* 3 Intarcon brand machines
* 3 máquinas marca Intarcon
* 2 Keyter brand machines
* 2 máquinas marca Keyter
* N generic thermostats
* N termostatos genéricos
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
In this example, the [[ModbusRTU-RS485#Steps in connecting the RS485 line with kiconex|steps for connection]] section would look like this:
En este ejemplo, el apartado de [[ModbusRTU-RS485#Pasos en la conexión de la línea RS485 con kiconex|pasos para la conexión]] quedaría así:
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
1 - Equipment distribution: equipment distribution is carried out based on its RS485 configuration
1 - Distribución de equipos: se realiza una distribución de equipos a partir de su configuración RS485
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
* Intarcon devices: speed 9600, parity bits none, stop bits 1: '''9600,8N1'''
* Equipos de Intarcon: velocidad 9600, bits de paridad ninguna, bits de parada 1: '''9600,8N1'''
* Keyter equipment: speed 19200, parity bits none, stop bits 2: '''19200,8N2'''
* Equipos de Keyter: velocidad 19200, bits de paridad ninguna, bits de parada 2: '''19200,8N2'''
* Generic thermostats: speed 9600, parity bits none, stop bits 1: '''9600,8N1'''
* Termostatos genéricos: velocidad 9600, bits de paridad ninguna, bits de parada 1: '''9600,8N1'''
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
{| class="wikitable"
{| class="wikitable"
|+
|+
!NOMBRE DEL EQUIPO
!NAME OF THE DEVICE
!PUERTO RS485
!RS485 PORT
!DIRECCIÓN MODBUS
!MODBUS ADDRESS
|-
|-
|Enfriadora 1
|Chiller 1
|1
|1
|1
|1
|-
|-
|Evaporador
|Evaporator
|1
|1
|2
|2
|-
|-
|Enfriadora 2
|Chiller 2
|1
|1
|3
|3
|-
|-
|Climatizadora 1
|Air conditioner 1
|2
|2
|4
|4
|-
|-
|Climatizadora 2
|Air conditioner 2
|2
|2
|5
|5
|-
|-
|Termp. sala 1
|Term. room 1
|N
|N
|100
|100
|-
|-
|Termp. sala 2
|Term. room 2
|N
|N
|101
|101
Línea 127: Línea 105:
|...
|...
|-
|-
|Termp. sala N
|Term. room N
|N
|N
|N
|N
|}
|}
2 - Se conecta el bus 1 con los equipos de Intarcon al puerto 1 y el bus 2 al puerto 2. En el caso del bus N, se conecta a su respectivo puerto, con los N equipos que tenga conectados.
2 - Bus 1 is connected with the Intarcon equipment to port 1 and bus 2 to port 2. In the case of bus N, it is connected to its respective port, with the N equipment that is connected.
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
3 - The Modbus addresses in the "'''MODBUS ADDRESS'''" column are configured on the display of each machine.
3 - Se configuran en el display de cada máquina las direcciones Modbus de la columna "'''DIRECCIÓN MODBUS'''".
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
4 - Verify that each cable line is correct, using a multimeter, according to the instructions on the page [https://{{SERVERNAME}}/index.php/Special:MyLanguage/CheckWiring '''checking the RS485 line '''].
4 - Se verifica que cada línea de cable está correcta, empleando multímetro, según indicaciones recogidas en la página de [https://{{SERVERNAME}}/index.php/Special:MyLanguage/CheckWiring '''comprobación de la línea RS485'''].
</div>


<div lang="es" dir="ltr" class="mw-content-ltr">
5 - You access the platform [https://my.kiconex.com/ myKiconex] and begin to see information.
5 - Se accede a plataforma [https://my.kiconex.com/ myKiconex] y se empieza a ver información.
[[File:ESQUEMA CONEXIÓN RS485.png|center|image thumbnail|800x800px|Connection diagram of a Modbus RTU-RS485 network]]
[[Archivo:ESQUEMA CONEXIÓN RS485.png|centro|miniaturadeimagen|800x800px|Esquema de conexionado de una red Modbus RTU-RS485]]
</div>

Revisión actual - 14:12 27 ago 2024

Modbus RTU-RS485 connection


The Modbus RTU protocol through RS485 connections is a standard widely used in industrial environments, since it allows the fluid and effective exchange of information over long distances. However, to avoid any possible interference and have completely stable communication, it is necessary that the buses meet a series of requirements that are detailed on this page.

Wiring requirements

  • Use a halogen-free 3-wire shielded cable that provides protection against interference in Modbus RTU communication.
  • Distance of at least 20cm from power lines.
  • Respect the polarity of each RS485 connection
  • Connection between devices following a daisy-chain topology, as shown in the following image:
Connection of RS485 devices following a daisy-chain topology
  • Common: if there is a connection for a common cable, a cable will come out of the terminal block (or kibox) that will go from the common to the common of the first control. It is connected to the common and from there a splice comes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
  • + positive: A cable will come out of the terminal block (or kibox, depending on whether there is a kiconex electrical panel) that will go from the positive to the positive of the first control. It is connected to the positive and from there a splice goes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
  • - negative: A cable will come out of the terminal block (or kibox, depending on whether there is a kiconex electrical panel) that will go from the negative to the negative of the first control. It is connected to the negative and from there a splice goes out to the next control. The operation must be repeated as many controls are going to be connected together in the same port. The common will 'die' at the last control in the series.
  • GND ground without kiconex electrical panel: the mesh (the covering of the shielded cable) will be connected to the ground of the installation. Between the controls connected in series, the shield must be connected to each other. It will 'die' in the last control.
  • GND ground with kiconex electrical panel: from the GND terminal block the shield of the shielded cable is connected. The other end must be connected to the shield of the shielded cable of the next control connected in series. The shield will 'die' in the last control.

Characteristics that define Modbus RTU communication

Every control that connects to a Modbus RTU network with an RS485 connector has a series of characteristics or configurations that allow it to communicate through said protocol:

  • A unique Modbus address and different from the rest of the controls connected on the same line. The address value is set between 1 and 247.
  • A communication configuration, which must be the same as all the controls connected on that line. Depending on the model and manufacturer of the control, this configuration is static or configurable through parameters. By consulting the manufacturer's manual you can verify this information. The communication configuration variables are:
    • Speed or baudrate: 9600bps, 19200bps, etc.
    • Data bits: 7 or 8
    • Parity bits: none, even or odd
    • Stop bits: 1 or 2

Steps in connecting RS485 lines with kiconex

1 - Plan how the controls will be distributed between the different RS485 ports available on the kiBox. The page about facility planning explains this. It is important to take into account the characteristics of the Modbus protocol when making this plan. The following table is indicative when establishing said planning:

NAME OF THE TEAM RS485 PORT MODBUS ADDRESS
Control identifier Depending on the kiBox model, up to 4 Values from 1 to 247

2 - Connect as many buses or shielded cables as RS485 ports have been planned, each of these buses must follow the wiring requirements above.

3 - Configure manually in each control the Modbus address planned in point 1.

4 - Verify that all Modbus buses have been set correctly by performing a checking.

5 - Connect the buses to their respective RS485 ports on the kiBox, access myKiconex and begin operating the remote facility.

Connection example

The image below represents an example of a generic connection where they are connected:

  • 3 Intarcon brand machines
  • 2 Keyter brand machines
  • N generic thermostats

In this example, the steps for connection section would look like this:

1 - Equipment distribution: equipment distribution is carried out based on its RS485 configuration

  • Intarcon devices: speed 9600, parity bits none, stop bits 1: 9600,8N1
  • Keyter equipment: speed 19200, parity bits none, stop bits 2: 19200,8N2
  • Generic thermostats: speed 9600, parity bits none, stop bits 1: 9600,8N1
NAME OF THE DEVICE RS485 PORT MODBUS ADDRESS
Chiller 1 1 1
Evaporator 1 2
Chiller 2 1 3
Air conditioner 1 2 4
Air conditioner 2 2 5
Term. room 1 N 100
Term. room 2 N 101
... ... ...
Term. room N N N

2 - Bus 1 is connected with the Intarcon equipment to port 1 and bus 2 to port 2. In the case of bus N, it is connected to its respective port, with the N equipment that is connected.

3 - The Modbus addresses in the "MODBUS ADDRESS" column are configured on the display of each machine.

4 - Verify that each cable line is correct, using a multimeter, according to the instructions on the page checking the RS485 line .

5 - You access the platform myKiconex and begin to see information.

Connection diagram of a Modbus RTU-RS485 network
Connection diagram of a Modbus RTU-RS485 network