Other Parts Discussed in Thread: SYSCONFIG,
We are planning to implement EEPROM emulation in our application using the "EEPROM Emulation Type A Design" from MSPM0 SDK v1.20.1.6.
Please help with the following questions:
- Where is the linker command file for the EEPROM examples in the SDK? The CCS project examples for EEPROM Emulation Type A Design do not have a linker command file associated with them so these do not build. Please provide a linker command file or suggest one that can be used.
- What is the linker syntax we can use to split code memory allocation around the EEPROM emulation sectors? We are wanting to keep the Flash sectors associated with EEPROM emulation in the lower 32KB of Flash to take advantage of the additional write/erase endurance. To do this we have modified our linker command file MEMORY directive to split the 64KB Flash into three separate regions - FLASH_LOW, FLASH_EEPROM, an FLASH_HIGH. We then try to use the linker ">>" operator to allocate the .text sections into FLASH_LOW and FLASH_HIGH. However the, MSPM0 requirement for 8 byte alignment on a Flash word prevents the use of that operator. See below example excerpt from the linker command file showing what we are trying to do.
- The palign(8) operator conflicts with the split directive and the linker issues this warning, "#10092-D split placement (>>) ignored for ".text": cannot split object with PALIGN operator"
We are using CCS Eclipse 12.5 with TI Clang v2.1.2.LTS
MEMORY
{
...
FLASH_LOW (RX) : origin = 0x00000000, length = 0x000077FF /* First 30KB of FLASH */
FLASH_EEPROM (RX) : origin = 0x00007800, length = 0x0000800 /* EEPROM Emulation region of FLASH. Must be in bottom 32KB */
FLASH_HIGH (RX) : origin = 0x00008000, length = 0x0000FFF8 /* Upper 32KB of FLASH */
...}
SECTIONS
{
....
.text : palign(8) { *(.text) } >> FLASH | FLASH_HIGH /* Specify that program memory can be split across these MEMORY regions */
...}