PSRAM in XIAO_ESP32S3

Hello there!

I am working with the Xiao_ESP32S3 sense device for capturing images and storing them in an SD card. I noticed that when PSRAM is enabled, the image quality is great, and when disabled, the image quality is low. I understood what’s happening here.

Now, I can easily enable PSRAM from the Arduino IDE with Tools > PSRAM > OPI PSRAM in a normal scenario.

I am creating an application to generate codes for these devices, but the problem is that I won’t be using Arduino IDE to enable PSRAM, as my application should not be dependent on it. Since I am using Arduino-CLI to compile and upload the codes to Xiao_ESP32S3, I saw that the PSRAM was not enabled by default, which should have.

My question is, how do I enable PSRAM by default when I upload the code to esp32s3 using Arduino-CLI by default, or maybe by adding a piece of code or flags?

Hi there,
I see this tid-bit, albeit for PLio

Create the file .vscode/arduino.json and add the following content.

{
    "sketch": "<FOLDER_NAME>.ino",
    "configuration": "PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=921600,LoopCore=1,EventsCore=1,DebugLevel=none",
    "board": "esp32:esp32:esp32",
    "output": "build"
}

from this article here, Not sure if it helps You may be able to create a script to doit?
HTH
GL :slight_smile: PJ :v: