You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Classic ESP32: GPIO17 is not always needed for PSRAM #5334
if (gpio == 16 || gpio == 17) return !psramFound(); // PSRAM pins on ESP32-D0WDR2-V3 (these are IO)
prevents using GPIO17 together with PSRAM. Modules that have "in-package" PSRAM integrated (like ESP32-WROOM-32E-N8R2, ESP32-WROOM-32E-N4R2 based on ESP32-D0WDR2-V3 / ESP32-D0WDRH2-V3) do not use GPIO17 for PSRAM. In this case GPIO17 can be used for other purposes (for example for Ethernet clock).
GPIO17 is only used for PSRAM on modules with external "off-package" PSRAM (like WROOVER uses).
If we just allow the PIN on boards that do need gpio17 for PSRAM, we'll be facing lots of user complaints like "lights freeze after changing the pin, homeassistent cannot connect" 😉 . Similar if we unlock the pin via build flag, because users will often install the wrong firmware as they don't understand the difference - "ethernet broken after updating WLED".
It means we need a reliable way to identify - at runtime - the new package that you mention, while still keeping 16 & 17 protected on the normal "WROVER-B" boards.
If you have both kinds of boards at hand, can you do a quick check of what ESP.getChipModel() reports on both boards (arduino-esp32 v2.0.9) ? If the function returns a different string for internal "in-package" PSRAM modules, then it might be possible to change the line you mention into something like
if ((strncmp_P(PSTR("whatever-getChipModel-says"), ESP.getChipModel(), 15) == 0) { // allow gpio17 on modules with in-package PSRAMif (gpio == 16) return !psramFound();
if (gpio == 17) returntrue;
} elseif (gpio == 16 || gpio == 17) return !psramFound(); // PSRAM pins on ESP32-D0WDR2-V3 (these are IO)
Hi, unfortunately I only have ESP32-WROOM-32E-N8R2 with "in-package" PSRAM. ESP.getChipModel() reports "ESP32-D0WDR2-V3". It fits exactely to espressif documentation. There is also "ESP32-D0WDRH2-V3" with in-package PSRAM.
I would say for both GPIO17 should not be blocked.
So the code should be:
if ((strncmp_P(PSTR("ESP32-D0WDR2-V3"), ESP.getChipModel(), 15) == 0) || (strncmp_P(PSTR("ESP32-D0WDRH2-V3"), ESP.getChipModel(), 16) == 0)) { // allow gpio17 on modules with in-package PSRAM
if (gpio == 16) return !psramFound();
if (gpio == 17) return true;
} else if (gpio == 16 || gpio == 17) return !psramFound(); // PSRAM pins on modules with off-package PSRAM
According to espressif datasheet, there are two versions of ESP32-WROVER-(I)E modules. The version that uses 2MB in-package PSRAM (ESP32-D0WDR2-V3 based) and the version that uses 8 MB off-package PSRAM (ESP32-D0WD-V3 based). Only the second one uses GPIO17. The code above should also work correctly also for ESP32-WROVER-(I)E modules.
Activity
[-]Classic ESP32: GPIO17 is not alway needed for PSRAM[/-][+]Classic ESP32: GPIO17 is not always needed for PSRAM[/+]softhack007 commentedon Feb 1, 2026
Hi @wled-install 👋
If we just allow the PIN on boards that do need gpio17 for PSRAM, we'll be facing lots of user complaints like "lights freeze after changing the pin, homeassistent cannot connect" 😉 . Similar if we unlock the pin via build flag, because users will often install the wrong firmware as they don't understand the difference - "ethernet broken after updating WLED".
It means we need a reliable way to identify - at runtime - the new package that you mention, while still keeping 16 & 17 protected on the normal "WROVER-B" boards.
If you have both kinds of boards at hand, can you do a quick check of what
ESP.getChipModel()reports on both boards (arduino-esp32 v2.0.9) ? If the function returns a different string for internal "in-package" PSRAM modules, then it might be possible to change the line you mention into something likewled-install commentedon Feb 1, 2026
Hi, unfortunately I only have ESP32-WROOM-32E-N8R2 with "in-package" PSRAM. ESP.getChipModel() reports "ESP32-D0WDR2-V3". It fits exactely to espressif documentation. There is also "ESP32-D0WDRH2-V3" with in-package PSRAM.
I would say for both GPIO17 should not be blocked.
So the code should be:
According to espressif datasheet, there are two versions of ESP32-WROVER-(I)E modules. The version that uses 2MB in-package PSRAM (ESP32-D0WDR2-V3 based) and the version that uses 8 MB off-package PSRAM (ESP32-D0WD-V3 based). Only the second one uses GPIO17. The code above should also work correctly also for ESP32-WROVER-(I)E modules.
softhack007 commentedon Feb 14, 2026
PR #5338 merged; using gpio17 on this special board will be possible with a "V4" build (wled 16.0-alpha).