Hi there,
technically the section “SectionEwResource” is only used for font and bitmaps resources and can be placed in the external flash with this section define. The framebuffer is located within the SDRAM and its memory address isn't depended to “SectionEwResource”. By the way, the framebuffer memory use is defined in "Application/Source/ewconfig.h" and basically includes following lines of code:
#define SDRAM_BASE_ADDR 0xC0000000
#define SDRAM_SIZE_BYTES 0x800000
#define EW_USE_DOUBLE_BUFFER 1
#define FRAME_BUFFER_WIDTH 480
#define FRAME_BUFFER_HEIGHT 272
/* calculated addresses for framebuffer(s) */
#define FRAME_BUFFER_ADDR SDRAM_BASE_ADDR
#define FRAME_BUFFER_SIZE FRAME_BUFFER_WIDTH * FRAME_BUFFER_HEIGHT * FRAME_BUFFER_DEPTH
#if EW_USE_DOUBLE_BUFFER == 1
/* locate double-buffer at the end of the last SDRAM bank - this ensures
that front/back-buffer are located within different banks of the SDRAM */
#define DOUBLE_BUFFER_ADDR (SDRAM_BASE_ADDR + SDRAM_SIZE_BYTES - FRAME_BUFFER_SIZE)
#define DOUBLE_BUFFER_SIZE FRAME_BUFFER_SIZE
#else
#define DOUBLE_BUFFER_ADDR 0
#define DOUBLE_BUFFER_SIZE 0
#define NUMBER_OF_FIELDS 3
#endif
However, the needed RAM memory isn't just the .rodata, it is also the .bss part. Embedded Wizard has a dynamically memory management included, which means it not possible to estimate all needed RAM during the compilation time. This memory manager allocates and frees memory dynamically during the runtime and you can let print the sum of usage into the console by using the define “EW_PRINT_MEMORY_USAGE” within "Application/Source/ewconfig.h".
EW_PRINT_MEMORY_USAGE - If this macro is defined, a statistic information is
printed reporting the amount of memory allocated by Chora objects, strings and
resources. Additionally, the current total memory allocation and the maximum
peak value is printed.
With this information you can calculate the the average and peak RAM usage of you Embedded Wizard GUI like in following table:
Best regards,
Tim