ESP32-WiFi-Hash-Monster
ESP32-WiFi-Hash-Monster copied to clipboard
M5Stack Core2 issue: ESP32-WiFi-Hash-Monster.ino.elf section `.dram0.bss' will not fit in region `dram0_0_seg'
Hi there, I try to compile on Arduino IDE 2.03, but it fails due to this error:
ESP32-WiFi-Hash-Monster.ino.elf section `.dram0.bss' will not fit in region `dram0_0_seg'
region `dram0_0_seg' overflowed by 1392 bytes
c:/users/user.name/appdata/local/arduino15/packages/m5stack/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: C:\Users\user.name\AppData\Local\Temp\arduino-sketch-0A9AEE5B2B635D40CC623E13BC0C4B31/ESP32-WiFi-Hash-Monster.ino.elf section `.dram0.bss' will not fit in region `dram0_0_seg'
c:/users/user.name/appdata/local/arduino15/packages/m5stack/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: DRAM segment data does not fit.
c:/users/user.name/appdata/local/arduino15/packages/m5stack/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: DRAM segment data does not fit.
c:/users/user.name/appdata/local/arduino15/packages/m5stack/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r2-patch5/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: region `dram0_0_seg' overflowed by 1392 bytes
collect2.exe: error: ld returned 1 exit status
exit status 1
Compilation error: exit status 1
I tried to help myself and found a few hints that point to lv_conf.h: https://community.platformio.org/t/esp32-ld-region-dram0-0-seg-overflowed-by-156768-bytes/18753/2
and: https://github.com/lvgl/lv_port_esp32/issues/252
so i tried my luck by editing said lv_conf.h to use less RAM, but sadly no succes, compiling will still throw the same error. Any idea what else I could do/try to make this work?
thnx in advance!
and I found a solution on my own :) in case anyone reads this, please check this article: https://esp32.com/viewtopic.php?t=3059
basically you can check a .map file that (on Windows) you will find in your /temp folder, e.g.: C:\Users\user.name\AppData\Local\Temp\arduino-sketch-0A9AEE5B2B635D40CC623E13BC0C4B31
and then you open that file in a text editor and search for '.dram0.bss' after that word you find a list of all variables that affect dram usage.
for this wifi monster the culprit is: .bss.ssid_known 0x000000003ffc4af8 0x11f00
then searching the source for 'ssid_known' gives us this: ssid_info ssid_known[MAX_SSIDs];
and then MAX_SSIDs is set to: #define MAX_SSIDs 1792
I decreased this value to 1750 and then the project compiled and uploaded just fine
Thanks i have this issue. and i solved.
But on M5StackCore2 AWS LED bars do not work.