ESP-WROOM-32 Flash Size

markwj
Posts: 90
Joined: Tue Mar 08, 2016 5:03 am

Re: ESP-WROOM-32 Flash Size

Postby markwj » Fri Apr 28, 2017 6:09 am

This approach seems to work (external flash chip on different chip select GPIO).

Are there any 128Mbit flash chips that have been tested workable already with ESP-32?

It seems Winbond W25Q128FV was used with ESP8266 with success, but not recommended for new designs. So W25R128FV, but no stock?

markwj
Posts: 90
Joined: Tue Mar 08, 2016 5:03 am

Re: ESP-WROOM-32 Flash Size

Postby markwj » Sun May 28, 2017 2:25 pm

Experimenting with Winbond 25Q128, it seems to work.

Forcing to 3.3V (as I am using SD card also), and setting standard pins plus external flash chip select on GPIO22, I burn fuses:

Code: Select all

XPD_SDIO_FORCE         Ignore MTDI pin (GPIO12) for VDD_SDIO on reset    = 1 R/W (0x1)
XPD_SDIO_REG           If XPD_SDIO_FORCE, enable VDD_SDIO reg on reset   = 1 R/W (0x1)
XPD_SDIO_TIEH          If XPD_SDIO_FORCE & XPD_SDIO_REG, 1=3.3V 0=1.8V   = 1 R/W (0x1)
SPI_PAD_CONFIG_CLK     Override SD_CLK pad (GPIO6/SPICLK)                = 6 R/W (0x6)
SPI_PAD_CONFIG_Q       Override SD_DATA_0 pad (GPIO7/SPIQ)               = 7 R/W (0x7)
SPI_PAD_CONFIG_D       Override SD_DATA_1 pad (GPIO8/SPID)               = 8 R/W (0x8)
SPI_PAD_CONFIG_HD      Override SD_DATA_2 pad (GPIO9/SPIHD)              = 9 R/W (0x9)
SPI_PAD_CONFIG_CS0     Override SD_CMD pad (GPIO11/SPICS0)               = 22 R/W (0x16)
I tried v2.1 branch (esptool beta1), but always got:

Code: Select all

rst:0x10 (RTCWDT_RTC_RESET),boot:0x1b (SPI_FAST_FLASH_BOOT)
flash read err, 1000
Falling back to built-in command interpreter.
Then I set ESP-IDF to 'master' branch (seems to need latest beta3 of esptool), I can flash and work:

Code: Select all

I (50) boot: ESP-IDF v2.0-rc1-803-g1e0710f1 2nd stage bootloader
I (50) boot: compile time 22:04:06
I (85) boot: Enabling RNG early entropy source...
I (85) boot: SPI Speed      : 40MHz
I (85) boot: SPI Mode       : DIO
I (93) boot: SPI Flash Size : 16MB
But if I try to set QIO in menuconfig, I get a message:

Code: Select all

I (82) qio_mode: Enabling QIO for flash chip WinBond
E (83) qio_mode: Quad I/O is only supported for standard pin numbers or ESP32-D2WD. Falling back to Dual I/O.
Is that correct?

WiFive
Posts: 3529
Joined: Tue Dec 01, 2015 7:35 am

Re: ESP-WROOM-32 Flash Size

Postby WiFive » Sun May 28, 2017 3:38 pm

https://github.com/espressif/esp-idf/bl ... ode.c#L165

You can patch around this if you want.

sirc_xy
Posts: 1
Joined: Mon Aug 07, 2017 7:10 pm

Re: ESP-WROOM-32 Flash Size

Postby sirc_xy » Mon Aug 07, 2017 7:18 pm

Hi dear colleagues, I'm having trouble understanding how much memory do I have available for my code?

This thread says that when you use OTA partitions, you have 1MB available for your code, but what if I configure the partition table to "single factory app, no OTA"? will I then have more space for code? for example 3MB?

If anyone could help me I'd be grateful

markwj
Posts: 90
Joined: Tue Mar 08, 2016 5:03 am

Re: ESP-WROOM-32 Flash Size

Postby markwj » Tue Nov 21, 2017 7:21 am

From what I can tell, this arrangement breaks SD CARD support. I ca't get any reply from Espressif on my other issues raised regarding this, but SDCARD works fine with default WROOM-32 module, but breaks when this external flash arrangement is used.

Not recommended. Better to just source a 128Mb flash version of ESP32 WROOM (they are coming now).

markwj
Posts: 90
Joined: Tue Mar 08, 2016 5:03 am

Re: ESP-WROOM-32 Flash Size

Postby markwj » Tue Jan 09, 2018 5:20 am

markwj wrote:From what I can tell, this arrangement breaks SD CARD support. I ca't get any reply from Espressif on my other issues raised regarding this, but SDCARD works fine with default WROOM-32 module, but breaks when this external flash arrangement is used.
Issue is actually caused by ANY flash size >4MB (not just external flash). Replicated with ESP IDF v2.1.

It seems that Espressif have resolved this in the latest versions of the IDF (>3.0). I haven't looked specifically, but it seems that the fix was made in the last month or two. So long as using IDF 3.0b1 or later, external or internal 16MB flash and SD CARD seems to work fine.

Who is online

Users browsing this forum: Baidu [Spider] and 29 guests