I have a rather large Arduino project (in eclipse) that has a lot of debugging messages using the Serial.print commands ("some string texts") so that I can debug along this path.
One thing that I noticed is that I am reaching the limit for how many of them I can have in a project. If I become too much, the program stops in very strange places. That is: often long before my new addition of the print command is completed. A.
My project .hex file is about 20k at the moment. Arduino Uno limits about 30kb right? Therefore, it should not be too big.
So I feel that the actual problem is probably that maybe these sequential commands fill my sram. It is only 2 KB. I use a lot of libraries.
Is the Serial.print command ("some string text") occupying SRAM? Of course, gcc puts these lines in program space? but maybe it is not?
Or is it something else? I have an alternative theory about the existence of the serial.print buffer, and I probably just populate it with too many messages.
source share