Linker Example

This example links three object files named demo.c.obj, ctrl.c.obj, and tables.c.obj and creates a program called demo.out. The symbol SETUP is the program entry point.

Assume that target memory has the following program memory configuration:

Address Range Contents
0x0200 to 0x0A00 RAM
0x1100 to 0xFFF0 FLASH
0xFFE0 to 0xFFFF VECTORS

The output sections are constructed in the following manner:

Example 30 shows the linker command file for this example. Example 31 shows the map file.