ESP32 KSZ8863 Simple Switch Example Error
Posted: Wed Aug 20, 2025 5:35 pm
I'm using an ESP32-WROVER-E module with the KSZ8863 chip to give my ESP32 an Ethernet interface while also allowing my device to be daisy-chained to other devices. At first, I was testing the KSZ8863 with this breadboard mess.

I followed the schematic from the KSZ8863 ESP-IDF library example here: https://github.com/espressif/esp-eth-dr ... 863RLL.pdf with a few changes. For one thing, I'm using an external 50MHz oscillator and I wired it according to the datasheet for the KSZ8863 for clocking mode 4. With the breadboard circuit, after some troubleshooting, I got the I2C connection to the ESP32 to work, intermittently. For a little while after a reset, it would be able to detect when the Ethernet port was connected, and send that over the I2C interface. After a while, it would start throwing errors. I'm blaming the messy breadboard, but I'm not sure that is the problem as I've never had issues with long wires for I2C before. I only had one Ethernet jack wired, and when I plugged in a cable with a computer on the other end, the link light would light up, and start flashing wildly without stopping. Wireshark didn't show anything special. When I disconnected the cable, the lights stayed on forever, and the I2C never sent a disconnection message.
Anyway, now my PCB has arrived, and I've populated all the Ethernet related components. I did order a couple of the wrong values, so those have been replaced by through-hole resistors for this prototype.

This is the schematic for the PCB I designed: https://drive.google.com/file/d/1lTv22X ... sp=sharing
I'm running the simple switch example here: https://github.com/espressif/esp-eth-dr ... ple_switch
This is the error I'm getting:
I ran the Arduino I2C scan program, and after adding a few lines to keep the KSZ8863's reset line high, it found the chip on the I2C bus at 0x5F as it should.
Thanks for any help!

I followed the schematic from the KSZ8863 ESP-IDF library example here: https://github.com/espressif/esp-eth-dr ... 863RLL.pdf with a few changes. For one thing, I'm using an external 50MHz oscillator and I wired it according to the datasheet for the KSZ8863 for clocking mode 4. With the breadboard circuit, after some troubleshooting, I got the I2C connection to the ESP32 to work, intermittently. For a little while after a reset, it would be able to detect when the Ethernet port was connected, and send that over the I2C interface. After a while, it would start throwing errors. I'm blaming the messy breadboard, but I'm not sure that is the problem as I've never had issues with long wires for I2C before. I only had one Ethernet jack wired, and when I plugged in a cable with a computer on the other end, the link light would light up, and start flashing wildly without stopping. Wireshark didn't show anything special. When I disconnected the cable, the lights stayed on forever, and the I2C never sent a disconnection message.
Anyway, now my PCB has arrived, and I've populated all the Ethernet related components. I did order a couple of the wrong values, so those have been replaced by through-hole resistors for this prototype.

This is the schematic for the PCB I designed: https://drive.google.com/file/d/1lTv22X ... sp=sharing
I'm running the simple switch example here: https://github.com/espressif/esp-eth-dr ... ple_switch
This is the error I'm getting:
Code: Select all
E (376) i2c.master: I2C hardware NACK detectedThanks for any help!