How to connect two Arduino directly via Ethernet cable

How to create connection between two Arduino directly via Ethernet without router/AP?

Answer

To create communication between two Arduino directly via Ethernet, we need to:

Arduino #1 (Ethernet Shield) Arduino #2 (Ethernet Shield)
IP address10.101.1.210 10.101.1.211
Subnet mask255.255.255.0 255.255.255.0
Gateway 10.101.1.211 10.101.1.210
DNS 0.0.0.0 0.0.0.0

And then create a TCP connection between two Arduino: one Arduino acts as TCP server and the other acts as TCP client

For detail about TCP creation, please refer to communication between two Arduino via TCP

Please note: These are Amazon affiliate links. If you buy the components through these links, We will get a commission at no extra cost to you. We appreciate it.

The Best Arduino Starter Kit

※ OUR MESSAGES