WT32-ETH01: Ethernet stops working when using Sensors2MQTT Usermod

Hello everyone,

Today I got a WT32-ETH01 Board and it works fine with the standard WLED 0.13.0-b6 Ethernet firmware but if I compile a custom firmware (using a slightly modified Sensors2MQTT-Usermod) the Ethernet stops working when the board gets cut off power or gets rebooted via the UI.
In Detail: After I turn the Ethernet-Setting ON after the first fresh boot, the Ethernet works fine. If later the board loses power or I reboot WLED, the Ethernet suddenly stops working and nothing will bring it back (reboots etc). It can be seen because of the green LAN-LED, too. When its working the LED is blinking, when its not the LED keeps a steady green.
As I mentioned before the problem occurs when i try to use Sensors2MQTT (modified for HTU21D). My software shouldn’t be a problem as I use the same on multiple other ESP32s with the same Sensor without a problem. Another Usermod that I tried (SN_Photoresistor usermod) works fine whereas the BME280_v2 Usermod resulted in the same problem as with Sensors2Mqtt.

I know that the WT32-ETH01 has a limited amount of usable GPIOs. I think I tried all of these as I2C Pins, but especially GPIOs 14 and 15. Furthermore it’s important to know, that the WT32-ETH01 keeps working perfectly over Wifi when I set up the connection. Just the Ethernet won’t work.

I think it must be a Software problem but I really don’t know what might cause it. The last hours I tried many things like changing GPIOs, rebooting, testing the same code on other ESP32s, adjusting the code hoping that I might find a fix.

Maybe someone got an idea? ^^

I’ve read gpio 12 of set to high can cause an issue on reboot.

Did you find a solution?

No, whenever I2C is used on my WT32-ETH01 in combination with WLED the Ethernet stops working. I tried various pin combinations, various software adjustments (in Usermod and in WLED build) etc, but no luck there. SPI works fine with Ethernet howether.
I feel it is important to note, that all my software runs fine with a normal ESP32 Devkit Board. With the WT32-ETH01 the I2C Sensors work, too, but not together with Ethernet and that is like the whole point of this module.

There is difference between I2C and I2S ?

It just because I tried to use a INMP441 I2S sensor which only work at configuration time. I mean, when I active the LAN settings and save. Then without reboot it works. If I power OFF - ON. It’s no more possible to connect via LAN. It may be the same issue ?

I’m using GPIO 12,14,15 for I2S

Also WT32-ETH01 use wt32-s1 and in datasheet , we can see those capabilities

I’m compiled the last Wled version and I see this:

initE: Attempting ETH config: 1
initC: *** Ethernet successfully configured! ***
ETH ConnectedDisconnected!

At the configuration time (when you don’t have ETH configured)
I see that is working but not after a power off-on
initC: Ethernet successfully configured!
ETH Started
Writing settings to /cfg.json…
Forcing reconnect.
Access point disabled.
Connecting to mywifi…
ETH ConnectedDisconnected!
But the ip is not Wifi IP and I see also signal to 100%
image

I updated this issue APA102 don´t work with LAN8720 (WT32-ETH01) · Issue #2542 · Aircoookie/WLED · GitHub

If you are using SR you may want to raise an issue there as well.
I am not sure if they changed that code or not.

@blazoncek Indeed but it react same way with Wled. That’s why I updated the issue mentioned

If you can, play with “Forcing reconnect” part of the code.
Unfortunately I didn’t write that piece of code so have no knowledge of its behaviour.

1 Like

@blazoncek As you suggest me to open an issue, I’m starting to do it and well :slight_smile: . Take the opportunity to do another test, I compiled the DEV branch of the SRWled (v0.13.3-beta) and OTA upload from the wled.

  1. I’m surprise to retrieve Sound parameter already filled with previous value.
  2. It was connected with LAN :slight_smile:
  • Reboot
    → Still connected on LAN
  • Power Off-On
    → Still connected On LAN

Definetively the dev branch is react different as the master branch.
If I play a bit, it hangs and restart … most of the time but it’s seems LAN issue is gone.