C'est aussi mon avis. C'est pas le mieux pour debuter.
Enfin, je joins ici le programme desassemble pour creer le programme que tu veux, a toi de piocher ce qui t'interesses:
.NOLIST
#define equ .equ
#define EQU .equ
#define END .end
.LIST
_ChkFindSym equ 42F1h
_ErrUndefined equ 44B6h
_ErrBadGuess equ 44CBh
OP1M equ 847Ah
_LoadCIndPaged equ 501Dh
_LoadDEIndPaged equ 501Ah
tempSwapArea equ 82A5h
_CreateProtProg equ 4E6Dh
_FlashToRam equ 5017h
_ErrOverflow equ 4495h
_ZeroOP1 equ 41C5h
_FindSym equ 42F4h
OP1 equ 8478h
_DelVarArc equ 4FC6h
.org 9D95h
call Label1
ret z
bcall(_ChkFindSym)
jr nc, Label2
bcall(_ErrUndefined)
Label2:
ld a, b
or 00h
jp z, Label3
call Label4
xor a
push af
Label6:
pop af
inc a
cp 74h
jr nz, Label5
bcall(_ErrBadGuess)
Label5:
ld hl, OP1M
inc (hl)
push af
bcall(_ChkFindSym)
jr nc, Label6
pop af
ld a, (OP1M)
ld (Str1), a
call Label1
bcall(_ChkFindSym)
ld hl, 09h
add hl, de
bcall(_LoadCIndPaged)
ld a, c
inc a
ld (082A9h), a
ld e, a
ld d, 00h
add hl, de
bcall(_LoadDEIndPaged)
ex de, hl
ld (tempSwapArea), hl
push hl
call Label4
pop hl
bcall(_CreateProtProg)
ex de, hl
ld de, 02h
add hl, de
ld (082A7h), hl
call Label1
bcall(_ChkFindSym)
ld a, (082A9h)
ld l, a
ld h, 00h
add hl, de
ld a, b
ld de, 0Bh
add hl, de
push hl
ld hl, (082A7h)
ex de, hl
ld bc, (tempSwapArea)
pop hl
bcall(_FlashToRam)
call Label4
ld hl, 082AFh
ld (hl), 02h
call Label7
push de
call Label4
pop de
call Label8
jp Label9
Label7:
ld hl, Str2
rst 20h
bcall(_ChkFindSym)
jr nc, Label10
bcall(_ErrUndefined)
Label10:
ld a, b
or 00h
jr nz, Label11
ret
Label8:
ld hl, 08h
add hl, de
ex de, hl
ld hl, 08479h
ld bc, (082AFh)
ld b, 00h
ldir
ld a, 3Eh
ld (de), a
ret
Label9:
call Label7
ld hl, 1Ah
add hl, de
inc (hl)
ld a, (hl)
cp 05h
jr nz, Label12
bcall(_ErrOverflow)
Label12:
ld b, a
Label13:
inc hl
djnz Label13
ld a, (Str1)
ld (hl), a
ret
Label4:
ld hl, Str3
rst 20h
ret
Label11:
ld a, 0AFh
call 00050h
rst 10h
ld b, h
Label1:
bcall(_ZeroOP1)
ld a, 72h
ld (08479h), a
bcall(_FindSym)
and 1Fh
cp 04h
jr nz, Label14
ld hl, OP1
ld (hl), 05h
inc hl
ld a, (de)
ld (082AFh), a
ld c, a
or 00h
jr z, Label14
ld b, 00h
inc de
inc de
ex de, hl
ldir
ret
Str3:
.db 06h, 5Bh
Str1:
.db "A", 00h
Str2:
.db 05h, 5Bh, 00h
Label3:
call Label7
push de
call Label1
pop de
call Label8
ld hl, Str1
ld (hl), 00h
jp Label9
Label14:
call Label7
ld hl, 1Ah
add hl, de
ld a, (hl)
or 00h
ret z
dec (hl)
ld b, a
Label15:
inc hl
djnz Label15
ld a, (hl)
or 00h
ret z
ld hl, Str3
rst 20h
ld hl, OP1M
ld (hl), a
bcall(_ChkFindSym)
jr c, Label16
bcall(_DelVarArc)
Label16:
xor a
or 00h
ret
; Disassembled by Jimmy Conner - timagic@yahoo.com
; @ 11/09/2007 19:39:55
; Disassembler v1.6
; Total Opcodes: 162
; Total Data: 7
; Z80 AC - www.zed80asm.org
; Personal - www.timagic.cjb.net
.end
end