Startup Source Code - Freescale Semiconductor DSP56800E User Manual

Hide thumbs Also See for DSP56800E:
Table of Contents

Advertisement

#endif
2.6.2.1.4
Linker Command File Symbols
While linking, the linker replaces any zeros generated by compiler for external symbols with
proper values calculated during linking process when the physical addresses of the symbols are
known. Some values of external symbols can be also specified directly by the directives in the
linker command file.
The following symbols are specified by the LCF and provide physical address of memory
segments used in the startup code:
/* external constants defined in LCF */
extern _Lstack_addr;
extern _Ldata_size;
extern _Ldata_ROM_addr;
extern _Ldata_RAM_addr;
extern _Ldata2_size;
extern _Ldata2_ROM_addr;
extern _Ldata2_RAM_addr;
extern _Ldatap_size;
extern _Ldatap_ROM_addr;
extern _Ldatap_RAM_addr;
extern _Lbss_size;
extern _Lbss_start;
extern _Lbss2_size;
extern _Lbss2_start;
extern _Lbssp_size;
extern _Lbssp_start;
extern _Linternal_RAM_addr;
extern _Linternal_RAM_size;
extern _Linterrupt_vectors_addr;
2.6.2.2

Startup Source Code

The following subsections describe the source code of the Start assembly function.
asm void Start(void)
{
2.6.2.2.1
Initialize Interrupt Vectors Base Address
Depending on the state of the EXTBOOT and EMI_MODE pins during the system reset, the vector
table is located at the beginning of the Boot Program Flash or (if Boot Flash is not available) at
the beginning of the Program RAM. The startup code always updates the Vector Table Base
Address (VBA) to beginning of ".interrupt_vectors" section where the Quick_Start vector table is
located. By default this table is always put to the beginning of the Program RAM anyway.
By defining the ARCH_VECTBL_ADDR macro in the appconfig.h configuration file, the VBA
may be forced to a custom value.
/* relocate vector table properly */
#ifdef ARCH_VECTBL_ADDR
move.l ARCH_VECTBL_ADDR,A
#else
move.l #_Linterrupt_vectors_addr,A
#endif
asrr.l #7,A
move.w A0,ArchIO.Intc.vba
FREESCALE SEMICONDUCTOR
Targeting 56F8xxx Platform
Boot Sequence
2-41

Advertisement

Table of Contents
loading

Table of Contents