Page 1 of 1

esp32-U4WDH external PSRAM not being detected

Posted: Mon Jul 04, 2022 4:47 am
by Satvik728845
Context:
I have been trying to use an external PSRAM along with esp32 U4WDH. The PSRAM I am using is from espressif itself.

I have used the data pins as;
(These pin configurations are shown in the esp32 datasheet, I have tried both configurations and none of them can detect PSRAM)

SD_DATA_1 - SIO0/SI
GPIO17 - SIO1/SO
SD_DATA_0 - SIO2
SD_CMD - SIO3
SD_CLK - CLK
GPIO10 - CS#
GND - VSS
VDD_SDIO - VDD

Image


SD_DATA_1 - SIO0/SI
SD_DATA_0 - SIO1/SO
SD_DATA_3 - SIO2
SD_DATA_2 - SIO3
SD_CLK - SCLK
GPIO10 - CE#
GND - VSS
VDD_SDIO - VDD
Image

The embedded flash used in U4WDH has the same data pins and CLK pin.
I am using Arduino IDE for this. I have chosen "ESP32 Dev Module" as my board type and I have enabled the PSRAM via the Tools menu.
Image

The code with which I am trying to detect and get the size of PSRAM is;
[Codebox]

Code: Untitled.cpp Select all

 
#include <SPI.h>
#include <Arduino.h>
#include<esp32-hal.h>
void setup() {
Serial.begin(115200);
//delay(2000);
// pinMode(3,OUTPUT);
// delay(200);
//
// digitalWrite(3,HIGH);
// delay(500);
Serial.print("Total heap:");
Serial.println(ESP.getHeapSize());
Serial.print("Free heap: ");
Serial.println(ESP.getFreeHeap());
// Serial.print("TOtal psram size : ");
// Serial.println(esp_spiram_get_size());
Serial.print("PSRAM INIT : ");
Serial.println(psramInit());
Serial.print("PSRAM Found : ");
Serial.println(psramFound());
if(psramFound()){
// Serial.print("Total PSRAM using caps:");
// Serial.println(heap_caps_get_free_size(MALLOC_CAP_SPIRAM));
Serial.print("Total PSRAM:");
Serial.println(ESP.getPsramSize());
Serial.print("Free PSRAM: ");
Serial.println(ESP.getFreePsram());
// Serial.setDebugOutput(true);
}
}
void loop() {
delay(2000);
}
[/Codebox]


Problems:

This is the log that I get when I put the core debug level to "Verbose".
...............................................................................

ets Jul 29 2019 12:21:46

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 188777542, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0030,len:1344
load:0x40078000,len:13516
load:0x40080400,len:3604
entry 0x400805f0
[ 2][W][esp32-hal-psram.c:61] psramInit(): PSRAM not supported!
Total heap:365028
Free heap: 340280
PSRAM INIT : 0
PSRAM Found : 0


.....................................................................................

Other codes, which probably don't use PSRAM, work perfectly fine.


Things I have tried so far:

I have used the same code in EPS32-D0WD and ESP32-PICOD4, they show the PSRAM with size of it.

I have externally pull-ed up the chip select pin, but I don't get 3.3V at chip select.

Connected GPIO 4 to the chip select pin and In the code, I did digitalWrite HIGH.

Re: esp32-U4WDH external PSRAM not being detected

Posted: Thu May 29, 2025 6:06 pm
by vhaudiquet
Hello,

Sorry to revive this dead post, but I'm facing the same issue.
I tried connecting the ESP32-U4WDH with PSRAM, using a LY68L6400 PSRAM chip.
However, my design does not work.
After further investigation, I found out that :
The ESP32-U4WDH chip supports external PSRAM chips. However, only the ESP-PSRAMXXH chip released by Espressif is supported. Third-party PSRAM chips are not supported.
For hardware design, all the PSRAM pins except for the CS pin can be multiplexed with Flash. For more information, please refer to the ESP32 Hardware Design Guidelines.
Also, when designing the PCB, please make sure that the GND of the PSRAM to the GND of the ESP32-U4WDH is as short as possible; Otherwise, the signal quality may be affected.
(https://docs.espressif.com/projects/esp ... sram-chips)

I think my design has two issues: it doesn't use the official chip, and I actually used the same CS pin as the flash.
However, I'm not sure that my design would work even changing that, and I would like to still use the LY68L6400 chip.

Did you end up solving your problem ? What happened ?

Thank you !