espressif / esp-idf

Espressif IoT Development Framework. Official development framework for Espressif SoCs.
Apache License 2.0
13.66k stars 7.29k forks source link

What IO ports are used to connect the LAN8720 network cable to ESP32-S3? (IDFGH-10426) #11680

Closed hzhh110 closed 1 year ago

hzhh110 commented 1 year ago

Answers checklist.

IDF version.

v4.4.2

Operating System used.

Windows

How did you build your project?

VS Code IDE

If you are using Windows, please specify command line type.

None

What is the expected behavior?

What IO ports are used to connect the LAN8720 network cable to ESP32-S3? Previously, ESP32: IO17 ETH for clock PHY LAN8720 ETH CLK MODE=ETH CLOCK GPIO17 OUT (3) GPIORMII SignalESP32 EMAC FunctionNotes GPIO21 TX EN EMAC TX EN GPIO19 TX0 EMAC TXD0 GPIO22 TX1 EMAC TXD1 GPIO25 RX0 EMAC RXD0 GPIO26 RX1 EMAC RXD1 GPIO27 CRS DV EMAC RX DRV GPIO23 ETH MDC PIN GPIO18 ETH MDIO_ PIN

What is the actual behavior?

What IO ports are used to connect the LAN8720 network cable to ESP32-S3?

Steps to reproduce.

What IO ports are used to connect the LAN8720 network cable to ESP32-S3?

Build or installation Logs.

No response

More Information.

What IO ports are used to connect the LAN8720 network cable to ESP32-S3?

liguilini commented 1 year ago

s3 no longer supports RMII,it removed integrated MAC.You can use SPI ethernet chip,like w5500

hzhh110 commented 1 year ago

s3 no longer supports RMII,it removed integrated MAC.You can use SPI ethernet chip,like w5500

Is there a recommended IO port for ESP32-S3 to connect to W5500 using SPI? I have temporarily referenced the IO port corresponding to the camera in ESP-S3-EYE

Define CAMERA Module NAME "ESP-S3-EYE"

Define CAMERA PIN PWDN -1

Define CAMERA PIN RESET -1

Define CAMERA PIN VSYNC 6 OK

Define CAMERA PIN HREF 7 OK

Define CAMERA PIN PCLK 13 OK

Define CAMERA PIN XCLK 15 OK

Define CAMERA PIN SIOD 4 OK

Define CAMERA PIN SIOC 5 OK

Define CAMERA PIN D0 11 OK

Define CAMERA PIN D1 9 OK

Define CAMERA PIN D2 8 OK

Define CAMERA PIN D3 10 OK

Define CAMERA PIN D4 12 OK

Define CAMERA PIN D5 18 OK

Define CAMERA PIN D6 17 OK

Define CAMERA PIN D7 16 OK

kostaond commented 1 year ago

Here you can find default GPIO for SPI Ethernet modules. However, if you use ESP32-S3, you can connect it to whatever IO you want, see here. Note that it used to be an concern to use dedicated SPI pins via IO_MUX for ESP32 to be able to achieve higher SPI speed but it is no longer applicable to S3.

Please close this issue since it is not real issue.

KaeLL commented 1 year ago

but it is no longer applicable to S3

@kostaond Would you mind elaborating further on why is that?

kostaond commented 1 year ago

ESP32 _The GPIO matrix introduces flexibility of routing but also brings the following disadvantages: Increases the input delay of the MISO signal, which makes MISO setup time violations more likely. If SPI needs to operate at high speeds, use dedicated IO_MUX pins. Allows signals with clock frequencies only up to 40 MHz, as opposed to 80 MHz if IOMUX pins are used.

ESP32-S3 When an SPI Host is set to 80MHz or lower frequencies, routing SPI pins via the GPIO matrix will behave the same compared to routing them via IOMUX.

KaeLL commented 1 year ago

I meant what exactly is the cause behind this limitation on the vanilla ESP32 and how did you guys fix it on newer variants?

kostaond commented 1 year ago

@KaeLL, frankly speaking, I don't know. I'm software guy responsible for Ethernet... This question is beyond ESP-IDF scope. You can try to ask at ESP Forum.

I'm closing the GH issue since the original question has been addressed and there is no real issue related to the ESP-IDF.