I have modified a library for some external module that communicates over UART. I have finally got it working after many issues with this error from the IDE:
section `.text' will not fit in region `iram1_0_seg'
TMR_Status ICACHE_FLASH_ATTR
I can compile this fine, without ESP8266wifi.h and it leaves me with quite a lot of space left:
Sketch uses 291,160 bytes (27%) of program storage space. Maximum is 1,044,464 bytes.
Global variables use 43,340 bytes (52%) of dynamic memory, leaving 38,580 bytes for local variables. Maximum is 81,920 bytes.
however by simply adding in #include <ESP8266WiFi.h>, this error returns:
section `.text' will not fit in region `iram1_0_seg'
collect2.exe: error: ld returned 1 exit status
Error compiling.
Any help would be massively appreciated, I would like to debug this device over MQTT, but I cant at the moment.
No suggestion is too silly, I have been at this for a few days now

Many Thanks, Aaron