I need to store an initialised array in code area.
The HW is so, that when modifying this array by the program the whole 256-byte page where the array is located must be first erased and then written.
Therefore, I need to reserve 256-byte of code for my array, which actually is smaller than 256 bytes.
I know how to allocate the initialised array in the desired absolute address through the BL51 Locator.
What I don't know is how to reserve the 256 byte to ensure that the linker does not place code after the last element of the array (if this happened the code between the end of the array and the end the page will be erased).
I thought naively that writing in the uVision BL51 Locate tab something like
Code: ?CO?FLASH_DATA1_MOD(0X1000 - 0x10FF)
(where FLASH_DATA1_MOD is the C-file where I wrote the array, and the addresses a 256 byte interval)
would work. This is but no correct syntax.
Of course, I could define a 256-byte array and initialise the first elements of interest. However, it would be much nicer to do everything from the uVision BL51 Locate tab.
Do you know how?
Thanks in advance for the ideas!