I stole the body of my Makefile from the one in CHERT's devkit, and I've been using it to flash my examples and couldn't work out why my chip was reporting 32Mbit(512KB+512KB) on startup, when I was using flash mode 6, which should be 32Mbit(1024KB+1024KB).
It turns out there's a bug in CHERT's script - this is what is in his Makefile:
ifeq ($(SPI_SIZE_MAP), 6)
size_map = 6
flash = 4096
flashimageoptions += -fs 32m
ifeq ($(app), 2)
addr = 0x101000
endif
...
Setting -fs 32m is actually flash mode 4, and is 32Mbit(512KB+512KB). The correct line is actually:
flashimageoptions += -fs 32m-c1
But what is more interesting is that in researching this bug, I found several more flash modes, including 32m-c2, 64m and 128m. The last two are pretty obvious, but it was 32m-c2 that caught my eye. It appears this mode is Flash Mode 7, and is 32Mbit(2048KB+2048KB) - and apart from that there doesn't seem to be anything else written about it anywhere.
I assume it gives us approx. 2048KB user space for code, which would be very useful for larger programs, but wouldn't you have to change the ld files as well? The user_rf_cal_sector_set() routine that comes with esp-open-sdk would cope with this fine but the ones written into user_main.c in some of the examples wouldn't
Has anybody used this mode? Experiences?