This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi everyone,
I am trying to save my current values in a large (0x004000 sized) array in global shared RAM of f28375d. I set up a variable then located it in RAMGS-1-2 when I try to build it gives an error saying that;
the program will not fit into .cinit memory location due being too large.
I can not make this array a constant one and I assume it should be initialized with a set of values from the .cinit location.
The current solution that I come up with is allocating more empty memory to .cinit that is enough to fit my whole array but then that memory is useless later on.
Is there a way to initialize this array with zeros in a way that no extra memory is needed for .cinit ?
Initializing the array such that;
#pragma DATA_SECTION(Current1ReadValues,"CURRENT_1_READ_LOCATION")
uint16_t Current1ReadValues[8192] = {0};
instead of
uint16_t Current1ReadValues[8192] = {0,0,0,0,........,0,0,0,0};
solved my problem, --zero-init=on and --cinit-compression did no effect.