I'm hoping that someone here can point me in the right direction with a memory issue that I'm running into on a NodeMCU esp8266 board.
I wrote a sketch on various Arduino boards, and I think the last one was on an Arduino Mega (earlier versions were running on a pro-mini without issue, though I'm not sure the latest version would fit in the 2K .. though it actually might still, it really isn't that big) ... anyway, I decided to move it over to the ESP in order to use the WIFI, and the sketch by itself compiles and runs fine ... once I add a VERY basic web server I get ".../multi-pattern3.ino.elf section
.text' will not fit in region iram1_0_seg'" (and by basic, I'm essentially just trying to integrate the "hello world" code example.
Considering how much more memory the ESP has; this was a bit unexpected, to the least. So after lots of research, I found the need for the ICACHE_FLASH_ATTR directive, in order to move the functions out of iram and into flash, but I don't think it's actually working. That said, is there a way that I can tell? Or is there a distinct functional example somewhere that someone could point me towards?, perhaps I'm simply not implementing it correctly, or maybe it doesn't even work in this case?
All of the explanations I found have been about as clear as mud because I'm learning C++ as I go here, so any insight would be extremely appreciated.
I'm using the Arduino 1.8.5 IDE if that's important.