跳至主要內容
Knowledgebase
Home
Renesas Electronics Taiwan - Knowledgebase

Defining the allocation of initial values to the data flash area (CC-RL)

Last Updated:05/10/2017

Question:

I am using the CC-RL compiler for RL78 devices. How can I define the assignment of initial values to the data flash area?

Answer:

To define the allocation, use #pragma section to name an allocation which is different from the default when defining const constants (as an array), then specify the address of the section with the -STARt option of the linker.

Note that you also need to specify the -NO_CHECK_SECTION_LAYOUT option of the linker when allocating a section to an address in data flash memory when using V1.02.00 or an earlier version of CC-RL.

When you set this option, you need to use a map file to check the consistency of the address information since it selects no checking for consistency of the address information for sections.

Suitable Products
e² studio
CS+ (formerly CubeSuite+)
C Compiler Package for RL78 Family