|
|
|
Compiler
MetrowerksHC12CC
CodeWarrior HC12 C Compiler
Settings of the compiler:
- parameters of the compiler-specific code generation,
- parameters of the compilation.
|
Settings:
-
Compiler - Compiler identification (change target compiler in Project panel - Cpu local menu - Application options).
-
Generate macros - Generate macros to the project modules. If intention and implementation of some beans' methods allow effective representation methods as macros, these methods will be generated as macros by setting of this property to "yes". Generating methods as macros can reduce code size. Disabling macros can facilitate debugging of the application code.
-
User initialization - In this group user can specify own initialization code that will be executed after reset (see also the Reset Scenario).
-
User data declarations - In this property user can specify own data declarations. Lines from this list will be generated before function _EntryPoint located in the CPU module.
-
User code before PE initialization - In this property user can specify own initialization code. Lines from this list will be generated before any code generated by PE to the function _EntryPoint located in the CPU module.
-
User code after PE initialization - In this property user can specify own initialization code. Lines from this list will be generated between the PE initialization code and the jump to __Startup (C initialization), to the function _EntryPoint located in the CPU module.
-
Serial monitor support - This property enables or disables support of Freescale Serial monitor (see Freescale application note AN2548). If this property is enabled, the following actions are done:
- The RE and TE bits of selected SCI channel are tested during CPU initialization code. If these bits are already set, the generated code supposes that Serial monitor is running and skips initialization of PLL and memory mapping registers. It is user's responsibility to set PLL timing to match settings of the Serial monitor.
- Used SCI channel is allocated and may not be used in PE (optionally).
- Memory area for Serial monitor code is allocated (and may not be used by other beans and linker). It is user's responsibility to set other memory mapping to match settings of the Serial monitor.
-
Channel - SCI Channel used by the Serial monitor.
-
Allocate SCI channel - If this propery is set to 'yes' then the selected SCI channel is allocated for exclusive use of the Serial monitor and cannot be useb by other beans.
-
Preserved memory - Memory area preserved for Serial monitor code.
-
Address - Memory area preserved for Serial monitor code - hex address. This item is for information only.
-
Size - Memory area preserved for Serial monitor code - hex size. This item is for information only.
-
Memory model - Memory model that is used by compiler. When the Small memory model is set the memory banks are disabled. Note: When you change the memory model check the memory model setting of the compiler and used library.
There are 2 options:
- Small: Small memory model
- Banked: Banked memory model
-
Generate PRM file - Rewrite LINKFILE during code generation. If you would like to add some parts to the link file you should set this property to 'no'. In the first time this property should be set to 'yes' for linkfile's creation.
-
Stack specification - Specification of the stack in the PRM linker file. The stack can be defined by a size or a top address. If the stack is disabled any setting of the stack will not be available in the PRM linker file (see the linker manual for information).
There are 3 modes:
- size - Stack is defined by size and it is put behind the used memory in a RAM area. The following items are displayed in this mode:
- top address - Stack is defined from the top address down to the begin of a RAM area where is the address defined. The following items are displayed in this mode:
- disabled - Stack is not defined. There are no items in this mode.
-
Set memory areas default - Click to set default memory areas according to current CPU bean settings (memory mapping and memory model). See CPU memory map window for detail about current memory mapping and available sizes.
-
ROM/RAM Areas - List of available memories. For each memory you must specify: start address, length in bytes and type: ROM or RAM. You must define at least two memories: for code and for data.
One item of the list looks like:
Memory Area0 - Memory area group.
-
ROM/RAM Area - ROM/RAM memory section for data or code.
-
Name - Area name
-
Address - Start address of the area. This address must be in internal or external memory (if an external bus is supported by the selected derivative). Addresses greater then 0xFFFF are considered to be a global addresses.
-
Size - Size of the area
-
Qualifier - Type of the memory area (read only, read/write, ...)
There are 4 options:
- READ_WRITE: Used for address ranges, which are initialized by the startup code at runtime. Memory area defined with this qualifier will be initialized with 0 at application startup. Processor Expert: PRM file will be generated to use this area for DATA.
- READ_ONLY: Used for address ranges, which are initialized at program load time. Processor Expert: PRM file will be generated to use this area for CODE and CONSTANT DATA.
- NO_INIT: Used for address ranges, where read write accesses are allowed. Memory area defined with this qualifier will not be initialized with 0 at application startup. This may be useful if your target has a battery buffered RAM or to speedup application startup.
- PAGED: Used for address ranges, where read write accesses are allowed. Memory area defined with this qualifier will not be initialized with 0 at application startup. Additionally, the linker will not control if there is an overlap between segments defined with the PAGED qualifier. When overlapped segments are used, it is the user’s responsibility to select the correct page before accessing the data allocated on a certain page.
-
PE compiler/linker support - Generate LINKFILE according to Metrowerks requirements if this property is "no". This feature is for integration of PE into the CodeWarrior environment. Warning: If you select this option to "no", the compilation (make or build) from the Processor Expert will not work.
-
Tool directory - Metrowerks compiler directory, default value is C:\Metrowerks\. User should specify directory where the Metrowerks Code Warrior is installed. The Processor Expert assumes that the compiler and linker are stored in the "prog" subdirectory. Path into prog directory is generated into the makefile by Processor Expert automatically. This is an item with global item value. If you set it once and PE remembers the value it will be used also in the future.
-
Generate MAKEFILE - Rewrite MAKEFILE during code generation.
-
Compiler - Directives for the Metrowerks C compiler.
-
Linker - Directives for the Metrowerks linker.
|
|
|
Processor ExpertTM and Embedded BeansTM are registered trademarks of UNIS, Ltd.
©1997-2005, UNIS, Ltd.
|
|
|