ESP32S3 Ethernet to ESP32S3 Ethernet direct connection witout router

bohdan1348
Posts: 1
Joined: Mon Nov 18, 2024 9:08 pm

ESP32S3 Ethernet to ESP32S3 Ethernet direct connection witout router

Postby bohdan1348 » Mon Nov 18, 2024 9:14 pm

The idea is to connect two ESP32s3 directly without a router through Ethernet using two W5500 SPI modules.

Current status:

- 2 ESP with W5500 modules are connected
- Used CrossOver cable
- RJ45 Green and Yellow LEDs are ON on both sides.

On one side I use a basic ethernet example with some changes in code. LOG:
I (8356) esp_netif_handlers: eth0 ip: 169.254.189.155, mask: 255.255.0.0, gw: 0.0.0.0
I (8356) eth_example: Ethernet Got IP Address
I (8356) eth_example: ~~~~~~~~~~~
I (8356) eth_example: ETHIP:169.254.189.155
I (8366) eth_example: ETHMASK:255.255.0.0
I (8366) eth_example: ETHGW:0.0.0.0
I (8376) eth_example: ~~~~~~~~~~~

On the other hand, I use the same example with integrated ICMPecho to have a PING possibility. LOG:
I (2388) eth_example: Ethernet Link Up
I (2388) eth_example: Ethernet HW Addr 36:85:18:49:26:20
I (2388) esp_netif_handlers: eth ip: 169.254.189.156, mask: 255.255.0.0, gw: 0.0.0.0
I (2388) eth_example: Ethernet Got IP Address
I (2398) eth_example: ~~~~~~~~~~~
I (2398) eth_example: ETHIP:169.254.189.156
I (2408) eth_example: ETHMASK:255.255.0.0
I (2408) eth_example: ETHGW:0.0.0.0
I (2418) eth_example: ~~~~~~~~~~~
I (4498) main_task: Returned from app_main()
esp> ping 169.254.189.155
esp> From 169.254.189.155 icmp_seq=1 timeout
From 169.254.189.155 icmp_seq=2 timeout


Could somebody help me with that? Is it possible to communicate in such a way?

ESP_ondrej
Posts: 211
Joined: Fri May 07, 2021 10:35 am

Re: ESP32S3 Ethernet to ESP32S3 Ethernet direct connection witout router

Postby ESP_ondrej » Wed Nov 20, 2024 8:49 am

If I understand your use case correctly, it is of course possible. It's the basic use case.

W5500 Datasheet specifies:
W5500 does not support auto-MDIX feature.
Thus, user should use straight-through cables to connect to other switches or routers and
crossover cables to connect to devices such as servers, workstations or another W5500.
However, user can use either type of cable to connect to other devices with auto-MDIX
enabled, and the interface automatically corrects for any incorrect cabling.


If I were you, I would:
1) start with with unmodified `Basic example` and connecting to PC (or other device) with DHCP server. Then tried ping the W5500.
2) If step 1 worked, I would modify the example to use static IP configuration (if is this want you want) and then again tried to ping from PC.
3) If step 2 worked, I would modify the example to ping PC from W5500.
4) Even after all of these steps were successful, I would try to interconnect two W5500 devices.

Who is online

Users browsing this forum: Bing [Bot], nullbert and 68 guests