From e867fcab1a724ab76d1e32ef3c09bba507c12a61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Frank=20M=C3=B6hle?= <91616163+softhack007@users.noreply.github.com> Date: Tue, 27 Jan 2026 23:14:06 +0100 Subject: [PATCH] Change default LED pin to 4 in Ethernet builds GPIO 4 seems to be one of the few pins that is not used in ANY supported ethernet config. See https://github.com/wled/WLED/issues/5155#issuecomment-3614391561 --- wled00/const.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/wled00/const.h b/wled00/const.h index 6d1825d5..264c632f 100644 --- a/wled00/const.h +++ b/wled00/const.h @@ -611,7 +611,12 @@ static_assert(WLED_MAX_BUSSES <= 32, "WLED_MAX_BUSSES exceeds hard limit"); #define DEFAULT_LED_PIN 2 // GPIO2 (D4) on Wemos D1 mini compatible boards, safe to use on any board #endif #else - #define DEFAULT_LED_PIN 16 // aligns with GPIO2 (D4) on Wemos D1 mini32 compatible boards (if it is unusable it will be reassigned in WS2812FX::finalizeInit()) + #if defined(WLED_USE_ETHERNET) + #define DEFAULT_LED_PIN 4 // GPIO4 seems to be a "safe bet" for all known ethernet boards (issue #5155) + #warning "Compiling with Ethernet support. The default LED pin has been changed to pin 4." + #else + #define DEFAULT_LED_PIN 16 // aligns with GPIO2 (D4) on Wemos D1 mini32 compatible boards (if it is unusable it will be reassigned in WS2812FX::finalizeInit()) + #endif #endif #define DEFAULT_LED_TYPE TYPE_WS2812_RGB #define DEFAULT_LED_COUNT 30