Oops... I have posted too fast actually... Just made a mistake in the code of my serial bootloader, but it is working fine.
Maybe I can explain quickly:
When the option "Save Constant In xROM" is selected, it means that any of the "const" variables will be stored in the data flash memory. So in the *.s file, there will be some lines for the data memory.
If you already use the data flash to store variables, you need to make sure that the constants will not overwrite your datas. To do so, I have cut the Data flash memory in two parts in the command file (*.cmd). Here is the tip:
1/ Find the lines:
.x_internal_ROM (RW) : ORIGIN = 0x00001000, LENGTH = 0x1000
.p_internal_RAM (RWX) : ORIGIN = 0x0002F800, LENGTH = 0x0800
And change it to match your memory map. For example, my variables were stored in the dataflash from the address 0x00001000 to 0x000015FF, and then, it is free to add my constants. So I did:
.x_internal_ROM (RW) : ORIGIN = 0x00001000,
LENGTH = 0x600 .x_const_in_ROM (RW) : ORIGIN = 0x00001600, LENGTH = 0xA00 .p_internal_RAM (RWX) : ORIGIN = 0x0002F800, LENGTH = 0x0800
2/ Now find the lines:
.Data_xROM :
{
* (.const.data.char) # used if "Emit Separate Char Data Section" enabled
* (.const.data)
} > .x_internal_ROM
3/ Replace ".x_internal_ROM" by your new location's name, for my example it becomes:
.Data_xROM :
{
* (.const.data.char) # used if "Emit Separate Char Data Section" enabled
* (.const.data)
} > .
x_const_in_ROM4/ And job done. All my constants will be stored in the data flash memory from 0x1600 to 0x1FFF.