Skip to content

Commit 01b079e

Browse files
committed
Small HACK to powercycle the ethernet chip on boot
This increases the reliability of connecting after a reboot
1 parent 2dec3de commit 01b079e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/net_manager.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,14 @@ net_setup()
419419

420420
#ifdef ENABLE_WIRED_ETHERNET
421421
//ETH.setHostname(esp_hostname.c_str());
422+
423+
#ifdef PHY_PWR
424+
pinMode(PHY_PWR, OUTPUT);
425+
digitalWrite(PHY_PWR, LOW);
426+
delay(1000);
427+
digitalWrite(PHY_PWR, HIGH);
428+
#endif
429+
422430
ETH.begin();
423431
#endif
424432

0 commit comments

Comments
 (0)