LCD Type MCU
Syntax
name
name
PROC
ENDP
Description
The
PROC
and
ENDP
directives mark a block of code which can be called or jumped to from other
modules. The
PROC
creates a label
name
which stands for the address of the first instruction of a
procedure. The Cross Assembler will set the value of the label to the current value of the location
counter.
Example
toggle
mov
mov
xorm
mov
ret
toggle
PROC
tmpbuf, a
a, 1
a, flag
a, tmpbuf
ENDP
Syntax
[label:]
DC
expression1
[,expression2 [,...]]
Description
The
DC
directive stores the value of
expression1, expression2
etc., in consecutive mem-
ory locations. This directive is used for the CODE section only. The bit size of the result value is
dependent on the ROM size of the MCU. The Cross Assembler will clear any redundant bits;
expression1
has to be a value or a label. This directive may also be employed to setup the ta-
ble in the code section.
Example
table1: DC
0128h, 025CH
In this example, the Cross Assembler reserves two units of ROM space and also stores 0128H
and 025CH into these two ROM units.
Data Definition Directives
An assembly language program consists of one or more statements and comments. A statement or
comment is a composition of characters, numbers, and names. The assembly language supports inte-
ger numbers. An integer number is a collection of binary, octal, decimal, or hexadecimal digits along
with an optional radix. If no radix is given, the Cross Assembler uses the default radix (decimal). The ta-
ble lists the digits that can be used with each radix.
Radix
B
O
D
H
Type
Binary
Octal
Decimal
Hexadecimal
Digits
01
01234567
0123456789
0123456789ABCDEF
144
Home Index Bookmark Pages Text
Previous Next
Pages: Home Index