Advanced programmers advice needed.

Before setup() is called the main() function calls init() main() or init() create the instances of hardwareSerial for Serial, Serial1 etc. Each instance of hardwareSerial has 2x64 byte buffers. In addition to that the heap must be created and initialized. My theory is that doing all this is putting you over the 2.5k of sram!.

The compiler can only report static data space used. not anything allocated during startup.

There is a way (playground) to get the amount of free ram left at run time and it would be very easy to write a stub program to check how well the reported ram usage matches the actual at the beginning of setup().

Mark