ESP32 ethernet example is not working
Posted: Thu Nov 25, 2021 5:39 am
Hi anyone,
I use same 3 pcb boards to test the ethernet sample code,
But the results of the 3 pcb boards are different.
The following is my development environment and settings.
Hardware: ESP32-WROVER-B + IP101
IDF Version:v4.1
OS:windown + ESP Command Prompt
Configuration: Log info:
No.1: PHY init fail
No.2 : Can not get the ip
No.3: After flash, it can work fine. But when power-off and keep some times, it will become the same symptom as No.1
Because the conditions of the 3 pcbs are different, so I have no idea how to resolve it.
Can someone provide assistance to troubleshoot the error?
Thanks for your reading.
I use same 3 pcb boards to test the ethernet sample code,
But the results of the 3 pcb boards are different.
The following is my development environment and settings.
Hardware: ESP32-WROVER-B + IP101
IDF Version:v4.1
OS:windown + ESP Command Prompt
Configuration: Log info:
No.1: PHY init fail
- [0;32mI (12) [boot] ESP-IDF v4.1.1-1-g599be5b9bc-dirty 2nd stage bootloader[0m
- [0;32mI (12) [boot] compile time 17:54:32[0m
- [0;32mI (12) [boot] chip revision: 1[0m
- [0;32mI (16) [boot_comm] chip revision: 1, min. bootloader chip revision: 0[0m
- [0;32mI (23) [boot.esp32] SPI Speed : 40MHz[0m
- [0;32mI (28) [boot.esp32] SPI Mode : DIO[0m
- [0;32mI (32) [boot.esp32] SPI Flash Size : 16MB[0m
- [0;32mI (37) [boot] Enabling RNG early entropy source...[0m
- [0;32mI (42) [boot] Partition Table:[0m
- [0;32mI (46) [boot] ## Label Usage Type ST Offset Length[0m
- [0;32mI (53) [boot] 0 nvs WiFi data 01 02 00009000 00006000[0m
- [0;32mI (61) [boot] 1 phy_init RF data 01 01 0000f000 00001000[0m
- [0;32mI (69) [boot] 2 factory factory app 00 00 00010000 00100000[0m
- [0;32mI (76) [boot] End of partition table[0m
- [0;32mI (80) [boot_comm] chip revision: 1, min. application chip revision: 0[0m
- [0;32mI (88) [esp_image] segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x0d3a0 ( 54176) map[0m
- [0;32mI (117) [esp_image] segment 1: paddr=0x0001d3c8 vaddr=0x3ffb0000 size=0x02074 ( 8308) load[0m
- [0;32mI (121) [esp_image] segment 2: paddr=0x0001f444 vaddr=0x40080000 size=0x00404 ( 1028) load[0m
- [0;32mI (125) [esp_image] segment 3: paddr=0x0001f850 vaddr=0x40080404 size=0x007c8 ( 1992) load[0m
- [0;32mI (134) [esp_image] segment 4: paddr=0x00020020 vaddr=0x400d0020 size=0x2f07c (192636) map[0m
- [0;32mI (215) [esp_image] segment 5: paddr=0x0004f0a4 vaddr=0x40080bcc size=0x09ad8 ( 39640) load[0m
- [0;32mI (239) [boot] Loaded app from partition at offset 0x10000[0m
- [0;32mI (239) [boot] Disabling RNG early entropy source...[0m
- [0;32mI (240) [cpu_start] Pro cpu up.[0m
- [0;32mI (243) [cpu_start] Application information:[0m
- [0;32mI (248) [cpu_start] Project name: ethernet_basic[0m
- [0;32mI (254) [cpu_start] App version: 781b332-dirty[0m
- [0;32mI (260) [cpu_start] ELF file SHA256: 10e45567284965c7...[0m
- [0;32mI (266) [cpu_start] ESP-IDF: v4.1.1-1-g599be5b9bc-dirty[0m
- [0;32mI (272) [cpu_start] Starting app cpu, entry point is 0x40081270[0m
- [0;32mI (0) [cpu_start] App cpu up.[0m
- [0;32mI (283) [heap_init] Initializing. RAM available for dynamic allocation:[0m
- [0;32mI (290) [heap_init] At 3FFAE6E0 len 00001920 (6 KiB): DRAM[0m
- [0;32mI (296) [heap_init] At 3FFB37E0 len 0002C820 (178 KiB): DRAM[0m
- [0;32mI (302) [heap_init] At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM[0m
- [0;32mI (309) [heap_init] At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM[0m
- [0;32mI (315) [heap_init] At 4008A6A4 len 0001595C (86 KiB): IRAM[0m
- [0;32mI (322) [cpu_start] Pro cpu start user code[0m
- [0;32mI (340) [spi_flash] detected chip: generic[0m
- [0;32mI (341) [spi_flash] flash io: dio[0m
- [0;32mI (341) [cpu_start] Starting scheduler on PRO CPU.[0m
- [0;32mI (0) [cpu_start] Starting scheduler on APP CPU.[0m
- [0;32mI (359) [system_api] Base MAC address is not set, read default base MAC address from BLK0 of EFUSE[0m
- [0;31mE (459) [ip101] ip101_pwrctl(296): power up timeout[0m
- [0;31mE (459) [ip101] ip101_init(336): power control failed[0m
- [0;31mE (459) [esp_eth] esp_eth_driver_install(199): init phy failed[0m
- ESP_ERROR_CHECK failed: esp_err_t 0xffffffff (ESP_FAIL) at 0x400848dc
- file: "../main/ethernet_example_main.c" line 125
- func: app_main
- expression: esp_eth_driver_install(&config, ð_handle)
- ELF file SHA256: 10e45567284965c7
- Backtrace: 0x40084241:0x3ffb5690 0x400848df:0x3ffb56b0 0x400d5379:0x3ffb56d0 0x400d202a:0x3ffb5740 0x40084c4d:0x3ffb5760
- [0;32mI (12) [boot] ESP-IDF v4.1.1-1-g599be5b9bc-dirty 2nd stage bootloader[0m
- [0;32mI (12) [boot] compile time 17:54:32[0m
- [0;32mI (12) [boot] chip revision: 1[0m
- [0;32mI (16) [boot_comm] chip revision: 1, min. bootloader chip revision: 0[0m
- [0;32mI (23) [boot.esp32] SPI Speed : 40MHz[0m
- [0;32mI (28) [boot.esp32] SPI Mode : DIO[0m
- [0;32mI (32) [boot.esp32] SPI Flash Size : 16MB[0m
- [0;32mI (37) [boot] Enabling RNG early entropy source...[0m
- [0;32mI (42) [boot] Partition Table:[0m
- [0;32mI (46) [boot] ## Label Usage Type ST Offset Length[0m
- [0;32mI (53) [boot] 0 nvs WiFi data 01 02 00009000 00006000[0m
- [0;32mI (61) [boot] 1 phy_init RF data 01 01 0000f000 00001000[0m
- [0;32mI (69) [boot] 2 factory factory app 00 00 00010000 00100000[0m
- [0;32mI (76) [boot] End of partition table[0m
- [0;32mI (80) [boot_comm] chip revision: 1, min. application chip revision: 0[0m
- [0;32mI (88) [esp_image] segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x0d3d0 ( 54224) map[0m
- [0;32mI (117) [esp_image] segment 1: paddr=0x0001d3f8 vaddr=0x3ffb0000 size=0x02074 ( 8308) load[0m
- [0;32mI (121) [esp_image] segment 2: paddr=0x0001f474 vaddr=0x40080000 size=0x00404 ( 1028) load[0m
- [0;32mI (125) [esp_image] segment 3: paddr=0x0001f880 vaddr=0x40080404 size=0x00798 ( 1944) load[0m
- [0;32mI (134) [esp_image] segment 4: paddr=0x00020020 vaddr=0x400d0020 size=0x2f07c (192636) map[0m
- [0;32mI (216) [esp_image] segment 5: paddr=0x0004f0a4 vaddr=0x40080b9c size=0x09b20 ( 39712) load[0m
- [0;32mI (239) [boot] Loaded app from partition at offset 0x10000[0m
- [0;32mI (239) [boot] Disabling RNG early entropy source...[0m
- [0;32mI (240) [cpu_start] Pro cpu up.[0m
- [0;32mI (243) [cpu_start] Application information:[0m
- [0;32mI (248) [cpu_start] Project name: ethernet_basic[0m
- [0;32mI (254) [cpu_start] App version: 781b332-dirty[0m
- [0;32mI (260) [cpu_start] Compile time: Nov 23 2021 17:53:45[0m
- [0;32mI (266) [cpu_start] ELF file SHA256: 5a035742e77154c0...[0m
- [0;32mI (272) [cpu_start] ESP-IDF: v4.1.1-1-g599be5b9bc-dirty[0m
- [0;32mI (279) [cpu_start] Starting app cpu, entry point is 0x40081274[0m
- [0;32mI (0) [cpu_start] App cpu up.[0m
- [0;32mI (289) [heap_init] Initializing. RAM available for dynamic allocation:[0m
- [0;32mI (296) [heap_init] At 3FFAE6E0 len 00001920 (6 KiB): DRAM[0m
- [0;32mI (302) [heap_init] At 3FFB37E0 len 0002C820 (178 KiB): DRAM[0m
- [0;32mI (309) [heap_init] At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM[0m
- [0;32mI (315) [heap_init] At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM[0m
- [0;32mI (322) [heap_init] At 4008A6BC len 00015944 (86 KiB): IRAM[0m
- [0;32mI (328) [cpu_start] Pro cpu start user code[0m
- [0;32mI (346) [spi_flash] detected chip: generic[0m
- [0;32mI (347) [spi_flash] flash io: dio[0m
- [0;32mI (347) [cpu_start] Starting scheduler on PRO CPU.[0m
- [0;32mI (0) [cpu_start] Starting scheduler on APP CPU.[0m
- [0;32mI (365) [system_api] Base MAC address is not set, read default base MAC address from BLK0 of EFUSE[0m
- [0;32mI (385) [esp_eth.netif.glue] 40:f5:20:7b:75:f3[0m
- [0;32mI (385) [esp_eth.netif.glue] ethernet attached to netif[0m
- [0;32mI (395) [eth_example] Ethernet Started[0m
- [0;32mI (14395) [eth_example] Ethernet Link Up[0m
- [0;32mI (14395) [eth_example] Ethernet HW Addr 40:f5:20:7b:75:f3[0m
- [0;32mI (64395) [eth_example] Ethernet Link Down[0m
- [0;32mI (12) [boot] ESP-IDF v4.1.1-1-g599be5b9bc-dirty 2nd stage bootloader[0m
- [0;32mI (12) [boot] compile time 17:54:32[0m
- [0;32mI (12) [boot] chip revision: 1[0m
- [0;32mI (16) [boot_comm] chip revision: 1, min. bootloader chip revision: 0[0m
- [0;32mI (23) [boot.esp32] SPI Speed : 40MHz[0m
- [0;32mI (28) [boot.esp32] SPI Mode : DIO[0m
- [0;32mI (32) [boot.esp32] SPI Flash Size : 16MB[0m
- [0;32mI (37) [boot] Enabling RNG early entropy source...[0m
- [0;32mI (42) [boot] Partition Table:[0m
- [0;32mI (46) [boot] ## Label Usage Type ST Offset Length[0m
- [0;32mI (53) [boot] 0 nvs WiFi data 01 02 00009000 00006000[0m
- [0;32mI (61) [boot] 1 phy_init RF data 01 01 0000f000 00001000[0m
- [0;32mI (69) [boot] 2 factory factory app 00 00 00010000 00100000[0m
- [0;32mI (76) [boot] End of partition table[0m
- [0;32mI (80) [boot_comm] chip revision: 1, min. application chip revision: 0[0m
- [0;32mI (88) [esp_image] segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x0d3a0 ( 54176) map[0m
- [0;32mI (117) [esp_image] segment 1: paddr=0x0001d3c8 vaddr=0x3ffb0000 size=0x02074 ( 8308) load[0m
- [0;32mI (121) [esp_image] segment 2: paddr=0x0001f444 vaddr=0x40080000 size=0x00404 ( 1028) load[0m
- [0;32mI (125) [esp_image] segment 3: paddr=0x0001f850 vaddr=0x40080404 size=0x007c8 ( 1992) load[0m
- [0;32mI (134) [esp_image] segment 4: paddr=0x00020020 vaddr=0x400d0020 size=0x2f07c (192636) map[0m
- [0;32mI (215) [esp_image] segment 5: paddr=0x0004f0a4 vaddr=0x40080bcc size=0x09ad8 ( 39640) load[0m
- [0;32mI (239) [boot] Loaded app from partition at offset 0x10000[0m
- [0;32mI (239) [boot] Disabling RNG early entropy source...[0m
- [0;32mI (240) [cpu_start] Pro cpu up.[0m
- [0;32mI (243) [cpu_start] Application information:[0m
- [0;32mI (248) [cpu_start] Project name: ethernet_basic[0m
- [0;32mI (254) [cpu_start] App version: 781b332-dirty[0m
- [0;32mI (260) [cpu_start] ELF file SHA256: 10e45567284965c7...[0m
- [0;32mI (266) [cpu_start] ESP-IDF: v4.1.1-1-g599be5b9bc-dirty[0m
- [0;32mI (272) [cpu_start] Starting app cpu, entry point is 0x40081270[0m
- [0;32mI (0) [cpu_start] App cpu up.[0m
- [0;32mI (283) [heap_init] Initializing. RAM available for dynamic allocation:[0m
- [0;32mI (290) [heap_init] At 3FFAE6E0 len 00001920 (6 KiB): DRAM[0m
- [0;32mI (296) [heap_init] At 3FFB37E0 len 0002C820 (178 KiB): DRAM[0m
- [0;32mI (302) [heap_init] At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM[0m
- [0;32mI (309) [heap_init] At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM[0m
- [0;32mI (315) [heap_init] At 4008A6A4 len 0001595C (86 KiB): IRAM[0m
- [0;32mI (322) [cpu_start] Pro cpu start user code[0m
- [0;32mI (340) [spi_flash] detected chip: generic[0m
- [0;32mI (341) [spi_flash] flash io: dio[0m
- [0;32mI (341) [cpu_start] Starting scheduler on PRO CPU.[0m
- [0;32mI (0) [cpu_start] Starting scheduler on APP CPU.[0m
- [0;32mI (359) [system_api] Base MAC address is not set, read default base MAC address from BLK0 of EFUSE[0m
- [0;32mI (379) [esp_eth.netif.glue] 40:f5:20:7b:7c:1b[0m
- [0;32mI (379) [esp_eth.netif.glue] ethernet attached to netif[0m
- [0;32mI (389) [eth_example] Ethernet Started[0m
- [0;32mI (12389) [eth_example] Ethernet Link Up[0m
- [0;32mI (12389) [eth_example] Ethernet HW Addr 40:f5:20:7b:7c:1b[0m
- [0;32mI (20849) [esp_netif_handlers] eth ip: 192.168.68.232, mask: 255.255.255.0, gw: 192.168.68.1[0m
- [0;32mI (20849) [eth_example] Ethernet Got IP Address[0m
- [0;32mI (20849) [eth_example] ~~~~~~~~~~~[0m
- [0;32mI (20849) [eth_example] ETHIP:192.168.68.232[0m
- [0;32mI (20859) [eth_example] ETHMASK:255.255.255.0[0m
- [0;32mI (20859) [eth_example] ETHGW:192.168.68.1[0m
- [0;32mI (20869) [eth_example] ~~~~~~~~~~~[0m
- [0;32mI (26389) [eth_example] Ethernet Link Down[0m
Can someone provide assistance to troubleshoot the error?
Thanks for your reading.