Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
49
Task/Machine-code/Z80-Assembly/machine-code.z80
Normal file
49
Task/Machine-code/Z80-Assembly/machine-code.z80
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
;;;;;;;;;;;;;;;;;;; HEADER ;;;;;;;;;;;;;;;;;;;
|
||||
read "\SrcCPC\winape_macros.asm"
|
||||
read "\SrcCPC\MemoryMap.asm"
|
||||
read "\SrcALL\winapeBuildCompat.asm"
|
||||
read "\SrcALL\lib\z80_opcode_chart.asm"
|
||||
;;;;;;;;;;;;;;;;;;; PROGRAM ;;;;;;;;;;;;;;;;;;;
|
||||
org &1000
|
||||
ld hl,machine_code_area
|
||||
|
||||
;assembles the following:
|
||||
;LD A,7
|
||||
;ADD 12
|
||||
;DAA
|
||||
;CALL SHOWHEX
|
||||
;RET
|
||||
|
||||
ld (hl),&3E ;LD A,nn
|
||||
inc hl
|
||||
ld (hl),7
|
||||
inc hl
|
||||
ld (hl),&C6 ;ADD nn
|
||||
inc hl
|
||||
ld (hl),12
|
||||
inc hl
|
||||
ld (hl),&27 ;DAA
|
||||
inc hl
|
||||
ld (hl),&CD ;call
|
||||
inc hl
|
||||
ld (hl),&00 ;low byte of address of showhex
|
||||
inc hl
|
||||
ld (hl),&11 ;high byte of address of showhex
|
||||
inc hl
|
||||
ld (hl),&C9 ;RET
|
||||
|
||||
;FALLTHROUGH IS INTENTIONAL
|
||||
machine_code_area:
|
||||
;0 = nop
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
byte 0,0,0,0,0,0,0,0
|
||||
|
||||
org &1100
|
||||
read "\SrcCPC\winape_showhex.asm" ;showhex is at &1100 thanks to the org.
|
||||
read "\SrcCPC\winape_stringop.asm"
|
||||
Loading…
Add table
Add a link
Reference in a new issue