Hi!
I am using IDE version 0.11 on OSX with a Maple r5 and I am having memory problems compiling a code for addressing a lcd display. I was trying to buffer the images before displaying using a byte array. The screen is 128x128 and it stores color in 3 bytes per pixel. When I try to compile my code (with device r3+ flash selected) I get the following error:
-------------------------
elf section .bss' will not fit in region
ram'
/Applications/MapleIDE.app/Contents/Resources/Java/hardware/tools/arm/bin/../lib/gcc/arm-none-eabi/4.4.1/../../../../arm-none-eabi/bin/ld: region `ram' overflowed by 33784 bytes
-------------------------
To make sure that it was independent of my code I created an simple sketch where I only declare the array and use it once. The code looks like this:
-------------------------
byte buffer[128][128][3];
void setup(){
buffer[0][0][0] = 0x32;
}
void loop(){}
-------------------------
I got the same error:
-------------------------
elf section .bss' will not fit in region
ram'
/Applications/MapleIDE.app/Contents/Resources/Java/hardware/tools/arm/bin/../lib/gcc/arm-none-eabi/4.4.1/../../../../arm-none-eabi/bin/ld: region `ram' overflowed by 33768 bytes
collect2: ld returned 1 exit status
-------------------------
If my math is right:
128x128x3 = 48.952bytes ~ 49Kbytes
The documentation says that the Maple r5 should support out of 120KB (for what I have read in other posts 108KB because of the bootloader). However, it seems that it is not able to fit 49KB.
One of the things that does not look right to me is that the error talks about 'ram' when I have the "Maple Rev 3+ Flash" option selected in my tools menu. If there is overflow it should be of flash memory. Of course, 49KB don't fit on the ram (which is 20KB minus bootloader overhead) but they should fit in 108KB.
Am I doing something wrong? Can someone help with this?
Thanks in advance!!