Skip to content

Is core v2.0.1 compatible with W5500 ethernet module ? #5913

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
kbssa opened this issue Nov 22, 2021 · 6 comments
Closed

Is core v2.0.1 compatible with W5500 ethernet module ? #5913

kbssa opened this issue Nov 22, 2021 · 6 comments
Assignees
Labels
Type: Question Only question

Comments

@kbssa
Copy link

kbssa commented Nov 22, 2021

I can't manage to get the W5500 working over the v2.0.1 core with Arduino Ethernet library.

The ETH.h library is compatible with W5500 ? If so, is there any example or any guide where I can see how to make it work ?

Any help would be appreciated.

Now it's working over de core v1.0.6 with Arduino Ethernet library, but I want to upgrade to v2.0.1.

Thanks in advance.

@felmue
Copy link

felmue commented Nov 22, 2021

Hello @kbssa

I don't think ETH.h library is compatible with W5500 given this list in ETH.h:

typedef enum { ETH_PHY_LAN8720, ETH_PHY_TLK110, ETH_PHY_RTL8201, ETH_PHY_DP83848, ETH_PHY_DM9051, ETH_PHY_KSZ8081, ETH_PHY_MAX } eth_phy_type_t;

What is the exact issue you are getting with the Arduino Ethernet library? Compilation? Error at runtime?

Thanks
Felix

@VojtechBartoska VojtechBartoska added the Type: Question Only question label Nov 22, 2021
@SuGlider
Copy link
Collaborator

@kbssa

W5500 is supported by IDF 4.4 but the current Arduino v2.0.0+ Lib ETH.h does not implement it, yet.

About W5500 IDF support in Arduino Core v2.0.0+:

It can be found in sdkconfig file for ESP32.
https://github.com/espressif/arduino-esp32/blob/master/tools/sdk/esp32/sdkconfig#L618

W5500 initialization function from IDF 4.4 is included here:
https://github.com/espressif/arduino-esp32/blob/master/tools/sdk/esp32/include/esp_eth/include/esp_eth_mac.h#L456-L487

ESP-IDF example with W5500 is here, but this piece of code is not included within core 2.0.1 version of ETH.cpp:
https://github.com/espressif/esp-idf/blob/master/examples/ethernet/basic/main/ethernet_example_main.c#L225-L250

@SuGlider
Copy link
Collaborator

@kbssa

I could not find W5500 in Arduino Core v1.0.6

From ETH.h I found this list:
typedef enum { ETH_PHY_LAN8720, ETH_PHY_TLK110, ETH_PHY_IP101, ETH_PHY_MAX } eth_phy_type_t;

Which one of those options did you use to make W5500 work?

@kbssa
Copy link
Author

kbssa commented Nov 23, 2021

@kbssa

W5500 is supported by IDF 4.4 but the current Arduino v2.0.0+ Lib ETH.h does not implement it, yet.

About W5500 IDF support in Arduino Core v2.0.0+:

It can be found in sdkconfig file for ESP32. https://github.com/espressif/arduino-esp32/blob/master/tools/sdk/esp32/sdkconfig#L618

W5500 initialization function from IDF 4.4 is included here: https://github.com/espressif/arduino-esp32/blob/master/tools/sdk/esp32/include/esp_eth/include/esp_eth_mac.h#L456-L487

ESP-IDF example with W5500 is here, but this piece of code is not included within core 2.0.1 version of ETH.cpp: https://github.com/espressif/esp-idf/blob/master/examples/ethernet/basic/main/ethernet_example_main.c#L225-L250

Is there any working example ?

I have no idea on how to include it in my code as I am completely noob with IDF implemention.

@kbssa
Copy link
Author

kbssa commented Nov 23, 2021

@kbssa

I could not find W5500 in Arduino Core v1.0.6

From ETH.h I found this list: typedef enum { ETH_PHY_LAN8720, ETH_PHY_TLK110, ETH_PHY_IP101, ETH_PHY_MAX } eth_phy_type_t;

Which one of those options did you use to make W5500 work?

The W5500 works with the Arduino Ethernet library in Arduino Core v1.0.6.

@SuGlider SuGlider self-assigned this Feb 10, 2022
@SuGlider
Copy link
Collaborator

@kbssa
W5500 is compatible with any core since it uses SPI for communication with ESP32.
You may need to use the right Arduino Library.

Arduino has a standard library that works fine with W5500/W5100/W5200:
https://www.arduino.cc/en/Reference/Ethernet
https://github.com/arduino-libraries/Ethernet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Question Only question
Projects
None yet
Development

No branches or pull requests

4 participants