No Init variables inside an user section(IAR)

Discussion created by sebasira on May 22, 2013

Hello everybody!


I've learnt how to define a section and how to place variables inside it. Now I want a constant variable not to be initialized. I'm usign IAR workbench.


Rigth now, I'm doing as follow

#pragma location="MY_SECTION"

const int var1;


And var1 is indeed inside MY_SECTION wich is part of the PFLASH. But if I add the __no_init modifier, then var1 is placed in RAM... So my question is how can I put a variable inside MY_SECTION so it is not initialized?



Thank you!!!