Page 1 of 1

ESP32 - External flash memory - Quad SPI access question

Posted: Thu Apr 26, 2018 9:39 am
by wwwenrico
Hi folks,

Can we finally access the external SPI flash memory in quad read/write mode?

Thanks,
Enrico Migliore

Re: ESP32 - External flash memory - Quad SPI access question

Posted: Fri Apr 27, 2018 2:32 am
by ESP_Sprite
Erm - you mean the SPI flash your ESP32 program is running from? That's always been able to run in quad mode.

Re: ESP32 - External flash memory - Quad SPI access question

Posted: Thu May 03, 2018 3:31 am
by wwwenrico
Hi,

>> you mean the SPI flash your ESP32 program is running from?
Yes. I mean that.


We built a custom board with:

1. ESP32 chip
2. ISSI IS25LP128-JBLE 128 Mbit flash memory chip

We flashed a simple "Hello World" C program into the flash.

The program works fine.

At boot, we receive a debug message that says that the ESP32 chip is accessing the flash memory in DIO mode (dual) and not in QIO mode (quad).

Thanks,
Enrico Migliore

Re: ESP32 - External flash memory - Quad SPI access question

Posted: Thu May 03, 2018 4:10 am
by ESP_Sprite
Okay, I don't really understand your 'finally' then - accessing the program SPI in quad mode has always been possible from what I know. Just make sure to enable it in make menuconfig: Serial flasher config -> Flash SPI mode.

Re: ESP32 - External flash memory - Quad SPI access question

Posted: Thu May 03, 2018 8:25 am
by ESP_igrr
The message printed by ROM bootloader will indicate that DIO mode is used. This is correct — 2nd stage bootloader is being loaded in DIO mode, and then it performs the switch to QIO mode, if you have enabled QIO in menuconfig. Loading 2nd stage bootloader itself in QIO mode offers very little improvement to boot time (as most of the time is used for app image verification), so we don't offer such an option.

Re: ESP32 - External flash memory - Quad SPI access question

Posted: Thu May 03, 2018 1:34 pm
by wwwenrico
Hi,

if we enable the option "QIO" in the make menuconfig the ESP32 chip hangs and doesn't start.

If we enable the option "DIO" in the make menuconfig the ESP32 chip starts and all works just fine.

The VDD_SDIO pin is 3.3 Volts measured by an oscilloscope.
The flash memory is the ISSI IS25LP128-JBLE and the bus runs at 120 MHz maximum. It supports the QIO mode.
In production, we will most likely use the Gigadevice GD25Q32.

Thanks,
Enrico Migliore