mcafzap 2 Posted December 10, 2014 Share Posted December 10, 2014 I'm using a FR5969 board (Rev 2) with Energia version 14 on a Mac running OS X 10.10.1. My sketch uses a 32767 byte block of the device's 'ROM' for storage and in total the memory used is given as 46667 bytes of 65536. So the initial part of my code includes: #define PERSIST __attribute__((section(".text"))) and later... uint8_t TTFX[32767] PERSIST The program seems to run correctly except that I'm concerned about a warning: 'Assembler messages: C:\Documen~1\TBA\LOCAL~1\Temp\\ccAA9W6Q.s:1758:Warning: ignoring changed section attributes for .text (Actually, it produces the same error on Windows XP.) What I'd like to know is what is this error and if it's safe to ignore (must be incredibly doubtful). TIA Steve Quote Link to post Share on other sites
spirilis 1,265 Posted December 10, 2014 Share Posted December 10, 2014 It's safe to ignore. The linker script for the compiler has "permission attributes" for the different sections or more specifically the memory segments where they go. The default permissions for the ROM segment, where .text lives, is RX - Readable, Executable, but not Writable. In practice this isn't enforced or enforceable in any way besides the fact that it helps the compiler catch goofy mistakes like trying to put something writable in ROM ... ... except "ROM" on the FRAM chips isn't ROM, but FRAM, which IS writable. However the conventional name "ROM" is used in the msp430fr5969 linker script anyhow to allow the template section linker script to be used (I think that's how it works) without modification, so you end up with this benign warning since you are declaring an array that can be written to. mcafzap 1 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.