# Modbus TCP/IP

YuDash LYNX supports Modbus TCP/IP to read various PLC/HMIs through ethernet. In principle, following are the pre-requesites for using Modbus TCP/IP:

1. Valid Ethernet settings of YuDash LYNX for communication over TCP/IP.
2. LYNX is Modbus Client, who request the data. The given PLC is Modbus server, who will provide the data. LYNX can read multiple Modbus TCP/IP servers.
3. Following details of a given Modbus Server (PLC) are required for communication:

* **IP address** of PLC. For example: ***192.168.1.100***
* **IP Port** on which Modbus server is running. For example: ***502*** (standard port). Or ***8888*** (any port being used by PLC)
* **Modbus Server ID** as per protocol. For example: ***1*** (The Server ID of Modbus is similar to slave ID of Modbus RS-485)
* **Modbus Registers and Data Types** The mapping of registers and selection procedure is similar to Modbus RS-485

There are different network topology possible for interfacing PLC/HMI with LYNX using Modbus TCP/IP. For example:

#### A) Peer to Peer Direct Connection&#x20;

<figure><img src="https://1858257737-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FToww5EM1cml3ouN6fvnJ%2Fuploads%2FiknnyIq390FC6OTjLxX8%2Fmodbus_tcpip_1.jpg?alt=media&#x26;token=b59985b5-50e4-4017-9e04-26d2e3cda77b" alt=""><figcaption></figcaption></figure>

#### B) Through Ethernet Switch&#x20;

<figure><img src="https://1858257737-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FToww5EM1cml3ouN6fvnJ%2Fuploads%2Fd4ulpIu1YQKJ5djbxkTn%2Fmodbus_tcpip_2.jpg?alt=media&#x26;token=7adfa5e6-c778-403a-a453-8c9bf4ee1eae" alt=""><figcaption></figcaption></figure>

#### C) Through LAN Router with Static IP

<figure><img src="https://1858257737-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FToww5EM1cml3ouN6fvnJ%2Fuploads%2FLIR8UrT4w5Q8YZCiHKcD%2Fmodbus_tcpip_3.jpg?alt=media&#x26;token=86d1c4e1-a512-41c4-9465-721fb6e7c9d0" alt=""><figcaption></figcaption></figure>

#### &#x20;D) Through LAN Router with Dynamic IP

<figure><img src="https://1858257737-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FToww5EM1cml3ouN6fvnJ%2Fuploads%2FW6zpPsmKtiJ1d4YuuRdO%2Fmodbus_tcpip_4.jpg?alt=media&#x26;token=e6c8daa0-5a43-453c-8091-bc0039a9e144" alt=""><figcaption></figcaption></figure>

All the scenarios of Modbus TCP/IP are covered in the video below.

{% embed url="<https://youtu.be/nYAulkX165c>" %}
