adapted monitor command 'C'

This commit is contained in:
FeralChild64 authored and FeralChild64 committed 2021-01-26 00:03:07 +01:00
1 parent b87830c036
commit b33a7a2905
4 files changed
+52 -22

No files matched your search

+43
View File
@@ -0,0 +1,43 @@
; Based on BSM (Bit Shifter's Monitor)
Mon_Compare:
jsr Get_Param_Range ; Long_PC = source
+bcs Mon_Error ; Long_CT = count
jsr Get_LAC ; Long_AC = target
+bcs Mon_Error
lda Src_Addr_Mode
ora Dst_Addr_Mode
sta Src_Addr_Mode
lda Addr_Mode
sta Dst_Addr_Mode
jsr Print_CR
ldz #0
@loop:
lda Dst_Addr_Mode
sta Addr_Mode
jsr Get_From_Memory_LAC
sta Byte_TMP
lda Src_Addr_Mode
sta Addr_Mode
jsr Get_From_Memory_LPC
cmp Byte_TMP
beq @laba
jsr Print_LPC_Addr
@laba:
jsr Inc_LAC
jsr Inc_LPC
jsr Dec_LCT
bpl @loop
jmp Main