®
Syntax
name
PROC
name
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
PROC
mov
tmpbuf, a
mov
a, 1
xorm
a, flag
mov
a, tmpbuf
ret
toggle
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
Type
Digits
B
Binary
01
O
Octal
01234567
D
Decimal
0123456789
H
Hexadecimal
0123456789ABCDEF
108
A/D Type MCU
Summary of Contents for HT46R22
Page 7: ...vi A D Type MCU...
Page 9: ...viii A D Type MCU...
Page 10: ...P a r t I Microcontroller Profile Part I Microcontroller Profile 1...
Page 11: ...2 A D Type MCU...
Page 90: ...P a r t I I Programming Language Part II Programming Language 81...
Page 91: ...82 A D Type MCU...
Page 97: ...88 A D Type MCU...
Page 128: ...P a r t I I I Development Tools Part III Development Tools 119...
Page 129: ...120 A D Type MCU...
Page 140: ...Appendix Appendix 131...
Page 141: ...132 A D Type MCU...
Page 151: ...142 A D Type MCU...
Page 152: ...A p p e n d i x B Package Information Appendix B Package Information 143 B...
Page 161: ...A D Type MCU...
Page 162: ...Amendments...