Disassembling Output - Epson S5U1C62000A Manual

Epson cmos 4-bit single chip microcomputer manual
Table of Contents

Advertisement

8.5 Disassembling Output

The data/code mnemonics are restored from the target code. As for the branch instructions, a label will
be automatically generated like "LXXXX:" where XXXX denotes a hexadecimal number string. ".org"
pseudo-instruction is used to specify the starting location of each code block.
The following shows examples of disassembled sources:
Sample outputs
Absolute list file "test.abs"
Linker 62 ver x.xx Absolute list file "TEST.ALS" Sun May 03 14:16:16 1998
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
0100
15:
0101
16:
0102
17:
0103
18:
0104
19:
0105
20:
LOOP:
21:
0106
22:
0107
23:
0108
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
0200
36:
0201
37:
0202
38:
0203
39:
0204
40:
0205
41:
42:
43:
44:
45:
46:
0206
47:
0207
48:
0208
49:
0209
50:
020a
51:
020b
52:
020c
53:
020d
54:
020e
55:
020f
S5U1C62000A MANUAL
(S1C60/62 FAMILY ASSEMBLER PACKAGE)
; main.s
; test program (main routine)
;
;***** INITIAL SP ADDRESS DEFINITION *****
#define
SP_INIT_ADDR 0x80
;***** BOOT, LOOP *****
.global
.global
.org
0x100
BOOT:
e08
ld
a,SP_INIT_ADDR>>4
fe0
ld
sph,a
e00
ld
a, SP_INIT_ADDR&0xf
ff0
ld
spl,a
e42 (+)
pset 0x2
400
call
INIT_RAM_BLK1
e42 (+)
pset 0x2
406
call
INC_RAM_BLK1
006
jp
LOOP
; sub.s
; test program (subroutines)
.global RAM_BLK1
.org
0x200
;***** RAM block 1 initialize *****
.global INIT_RAM_BLK1
INIT_RAM_BLK1:
e00
ld
a,RAM_BLK1^h
e80
ld
xp,a
b00
ld
x,RAM_BLK1^l
900
lbpx
mx,0
900
lbpx
mx,0
fdf
ret
;***** RAM block 1 increment *****
.global INC_RAM_BLK1
INC_RAM_BLK1:
e00
ld
a,RAM_BLK1^h
e80
ld
xp,a
b00
ld
x,RAM_BLK1^l
e00
ld
a,0
f41
scf
f28
acpx
mx,a
f28
acpx
mx,a
f28
acpx
mx,a
a98
adc
mx,a
fdf
ret
INIT_RAM_BLK1
INC_RAM_BLK1
EPSON
CHAPTER 8: DISASSEMBLER
;SP init addr = 0x80
; subroutine
; subroutine
; set SP
; initialize RAM block 1
; increment RAM block 1
; infinity loop
;set RAM_BLK1 address to x
;set 0x0000 to RAM_BLK1
;set RAM_BLK1 address to x
; increment 16bit value
115

Advertisement

Table of Contents
loading

Table of Contents