beautypg.com

Copy base, Copy top, Divide) – Zilog Z8F0130 User Manual

Page 386: Copy base copy top / (divide)

background image

Using the Linker/Locator

UM013037-1212

362

Zilog Developer Studio II – Z8 Encore!
User Manual

/* RAM allocation */

LOCATE s_uninit_data at $800

LOCATE s_nvrblock at $900

DEFINE __low_data = BASE OF s_uninit_data

Using

LOCATE s_uninit_data at $800

or

LOCATE s_uninit_data at LOWADDR OF EDATA

gives the same address (the lowest possible address) when

RANGE EDATA $800:$BFF

.

If

LOCATE s_uninit_data at $800

is changed to

LOCATE s_uninit_data at BASE OF EDATA

the lowest used address is

$900

(because

LOCATE s_nvrblock at $900

and

s_nvrblock

is in

EDATA

).

COPY BASE

The COPY BASE operator provides the lowest used address of a copy segment, group, or
address space. The value of COPY BASE is treated as an expression value.

Syntax

COPY BASE OF

<name>

<name> can be either a group, address space, or segment.

COPY TOP

The

COPY TOP

operator provides the highest used address of a copy segment, group, or

address space. The value of COPY TOP is treated as an expression value.

Syntax

COPY TOP OF

<name> can be a group, address space, or segment.

/ (Divide)

The / (Divide) operator is used to perform division.