Memory Setting Pseudo-Instructions - Epson S1C62 Family Reference Manual

Cmos 4-bit single chip microcomputer development tool
Table of Contents

Advertisement

CROSS ASSEMBLER ASM62XX
DW (Define Word)
<Label>_DW_<Expression>
The DW pseudo-instruction assigns the value of <expression> (the low-order 12 bits when the value is
greater than 12 bits) to the current memory location, indicated by the location counter.
Examples:
Location counter
(BNK) (PCP) (PCS)
0
0
0
<label> can be omitted.

Memory setting pseudo-instructions

4.5.2
The program memory mounted at the S1C62XXX is divided into 256-step pages. Memory management
(including the setting of the program location and page boundaries) during program generation must be
controlled by the source program.
The memory setting pseudo-instructions are used to specify memory management. The assembler sets the
location counter according to these pseudo-instructions.
If a memory area that has already been used is specified or a statement that exceeds the page is used
without specifying that the statement is to exceed the page, the assembler displays an exclamation mark "!",
indicating a warning, and ignores all subsequent statements until the next correct statement. This should
be taken into account.
When using the auto-page-set function, the space for insertion of the "PSET" pseudo-instruction must be
allocated in each page.
ORG (Origin)
ORG_<Expression>
The ORG pseudo-instruction sets the location counter to the value of <expression>.
If the ORG pseudo-instruction is not written at the beginning of the program, the location counter is set
to 0 (BNK=0, PCP=0, PCS=0) and assembly is started.
The ORG pseudo-instruction can be used at multiple locations in the program. However, it cannot be
used to set the location to a value before the current location. If this is attempted, an exclamation mark
"!", indicating a warning, is displayed, and all subsequent statements until the next correct statement are
ignored.
A label can be written before the ORG statement, but it cannot be referenced because it is not cataloged
in the label table. In this case, write the label in the statement following the ORG pseudo-instruction.
Example:
START
An R-error occurs if a value is specified exceeding the ROM capacity.
Note The upper limit of program memory depends on the model. (Refer to the "S5U1C62xxxD
Manual".)
III-12
2
0A
TABLE
2
0B
2
0C
ORG
0100H
:
To preset data
DW
141H
; = RETD 'A'
DW
142H
; = RETD 'B'
DW
143H
; = RETD 'C'
:
To set the location counter
; BNK=0, PCP=1, PCS=00H
EPSON
DEVELOPMENT TOOL REFERENCE MANUAL
S1C62 FAMILY

Advertisement

Table of Contents
loading

This manual is also suitable for:

S1c62 series

Table of Contents