Tool/software: TI C/C++ Compiler
Why configure not standart section order in FRAM?
Need
//seg1 = const, read only
//seg2 = code = read + execute access
//seg3 = any read + write persistent variables
In this CMD not effects in automatic calculate
SECTIONS { .TI.noinit : {} > RAM /* For #pragma noinit */ .bss : {} > RAM /* Global & static vars */ .data : {} > RAM /* Global & static vars */ .stack : {} > RAM (HIGH) /* Software system stack */ GROUP(IPENCAPSULATED_MEMORY) { .ipestruct : {} /* IPE Data structure */ .ipe : {} /* IPE */ .ipe:_isr : {} /* IPE ISRs */ } PALIGN(0x0400), RUN_START(fram_ipe_start) RUN_END(fram_ipe_end) > FRAM GROUP(READ_ONLY_MEMORY) { .cinit : {} /* Initialization tables */ .pinit : {} /* C++ Constructor tables */ .init_array : {} /* C++ Constructor tables */ .mspabi.exidx : {} /* C++ Constructor tables */ .mspabi.extab : {} /* C++ Constructor tables */ .const : {} /* Constant data */ } PALIGN(0x0400), RUN_END(fram_rx_start) > FRAM GROUP(EXECUTABLE_MEMORY) { .text:_isr : {} /* Code ISRs */ .text : {} /* Code */ } PALIGN(0x0400), RUN_END(fram_rw_start) > FRAM GROUP(READ_WRITE_MEMORY) { .TI.persistent : {} /* For #pragma persistent */ .cio : {} /* C I/O Buffer */ .sysmem : {} /* Dynamic memory allocation area */ } PALIGN(0x0400), RUN_START(fram_rx_end) > FRAM logger_buff : {} > DATA2 type=NOINIT .jtagsignature : {} > JTAGSIGNATURE /* JTAG Signature */ .bslsignature : {} > BSLSIGNATURE /* BSL Signature */ GROUP(SIGNATURE_SHAREDMEMORY) { .ipesignature : {} /* IPE Signature */ .jtagpassword : {} /* JTAG Password */ } > IPESIGNATURE .infoA : {} > INFOA /* MSP430 INFO FRAM Memory segments */ .infoB : {} > INFOB .infoC : {} > INFOC .infoD : {} > INFOD /* MSP430 Interrupt vectors */ .... .reset : {} > RESET /* MSP430 Reset vector */ } /****************************************************************************/ /* MPU/IPE Specific memory segment definitons */ /****************************************************************************/ ..... // Segment definitions #ifdef _MPU_MANUAL // For custom sizes selected in the GUI mpu_segment_border1 = _MPU_SEGB1 >> 4; mpu_segment_border2 = _MPU_SEGB2 >> 4; mpu_sam_value = (_MPU_SAM0 << 12) | (_MPU_SAM3 << 8) | (_MPU_SAM2 << 4) | _MPU_SAM1; #else // Automated sizes generated by Linker //seg1 = const, read only //seg2 = code = read + execute access //seg3 = any read + write persistent variables mpu_segment_border1 = fram_rx_start >> 4; mpu_segment_border2 = fram_rw_start >> 4; mpu_sam_value = 0x1531; // Info R, Seg3 RW, Seg2 RX, Seg1 R #endif #ifdef _MPU_LOCK #ifdef _MPU_ENABLE_NMI mpu_ctl0_value = MPUPW | MPUENA | MPULOCK | MPUSEGIE; #else mpu_ctl0_value = MPUPW | MPUENA | MPULOCK; #endif #else #ifdef _MPU_ENABLE_NMI mpu_ctl0_value = MPUPW | MPUENA | MPUSEGIE; #else mpu_ctl0_value = MPUPW | MPUENA; #endif #endif
result map: