06.02.2013 Views

C166/ST10 Cross-Assembler, Linker/Locator, Utilities ... - Tasking

C166/ST10 Cross-Assembler, Linker/Locator, Utilities ... - Tasking

C166/ST10 Cross-Assembler, Linker/Locator, Utilities ... - Tasking

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

• • • • • • • •<br />

<strong>Linker</strong>/<strong>Locator</strong> 9−89<br />

symbol_class_base : the base address of the class where the section<br />

of the symbol belongs to. The class is one of<br />

the overlay classes and the address is set by the<br />

CLASSES control for this class.<br />

overlay_base : the base address of the overlay area. This<br />

address is set by the OVERLAY control.<br />

The locator does not accept more than one OVERLAY control.<br />

Example:<br />

In this example some hardware is used to switch between three memory<br />

banks, BANK1, BANK2 and BANK3. The hardware is steered by a software<br />

routine: the bankswitch function. Each bank is one EPROM or a set of<br />

EPROMs. The EPROM programmer takes care of extracting memory banks<br />

from the hex file and burning each bank in a separate EPROM. This is<br />

possible because each bank has its own address range.<br />

Figure 9−1 shows the memory map.<br />

BANK3<br />

BANK2<br />

BANK1<br />

OVERLAY AREA<br />

Figure 9−1: Memory map<br />

lab_in_bank3<br />

060000h<br />

lab_in_bank2<br />

050000h<br />

lab_in_bank1<br />

040000h<br />

010000h<br />

000000h<br />

Each bank is a set of sections all having the same class. In this case the<br />

classes are named ’BANK1’, ’BANK2’ and ’BANK3’. The application is<br />

located with the following locator invocation file:<br />

MEMSIZE( SEGMENT 7 )<br />

OVERLAY( BANK1, BANK2, BANK3 ( SEGMENT 1 TO SEGMENT 2 − 1 ) )

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!