initial adaptation of register set
This commit is contained in:
1 parent
96bdf93b76
commit
1d6d6df705
2 files changed
+60
-17
No files matched your search
@@ -423,23 +423,6 @@ Print_Bits:
|
|||||||
RTS
|
RTS
|
||||||
|
|
||||||
|
|
||||||
; ***************
|
|
||||||
Mon_Set_Register: ; XXX this needs adaptation
|
|
||||||
; ***************
|
|
||||||
|
|
||||||
JSR Get_LAC ; get 1st. parameter
|
|
||||||
JSR LAC_To_PC
|
|
||||||
LDY #3
|
|
||||||
@loop JSR Get_LAC
|
|
||||||
BCS @exit
|
|
||||||
LDA Long_AC
|
|
||||||
STA Addr_Mode,Y
|
|
||||||
INY
|
|
||||||
CPY #9
|
|
||||||
BCC @loop
|
|
||||||
@exit JMP Main
|
|
||||||
|
|
||||||
|
|
||||||
; *****
|
; *****
|
||||||
Mon_Go:
|
Mon_Go:
|
||||||
; *****
|
; *****
|
||||||
|
|||||||
@@ -0,0 +1,60 @@
|
|||||||
|
|
||||||
|
; Based on BSM (Bit Shifter's Monitor)
|
||||||
|
|
||||||
|
|
||||||
|
Mon_Set_Register:
|
||||||
|
|
||||||
|
; PC - 16 bit
|
||||||
|
|
||||||
|
jsr @helper_get_16_bit
|
||||||
|
|
||||||
|
lda Long_AC+0
|
||||||
|
sta PCL
|
||||||
|
lda Long_AC+1
|
||||||
|
sta PCH
|
||||||
|
|
||||||
|
; SR / AC / XR / YR / ZR / BP - 8 bit each
|
||||||
|
|
||||||
|
ldy #$00
|
||||||
|
|
||||||
|
@lpreg:
|
||||||
|
|
||||||
|
jsr Get_Val_To_LAC
|
||||||
|
beq @exit
|
||||||
|
jsr Syntax_Byte_AC
|
||||||
|
|
||||||
|
lda Long_AC+0
|
||||||
|
sta SR,Y
|
||||||
|
|
||||||
|
iny
|
||||||
|
cpy #$06
|
||||||
|
bne @lpreg
|
||||||
|
|
||||||
|
; SP - 16 bit
|
||||||
|
|
||||||
|
jsr @helper_get_16_bit
|
||||||
|
|
||||||
|
lda Long_AC+0
|
||||||
|
sta SPL
|
||||||
|
lda Long_AC+1
|
||||||
|
sta SPH
|
||||||
|
|
||||||
|
; Flags
|
||||||
|
|
||||||
|
; XXX
|
||||||
|
|
||||||
|
@exit:
|
||||||
|
|
||||||
|
jmp Main
|
||||||
|
|
||||||
|
|
||||||
|
@helper_get_16_bit:
|
||||||
|
|
||||||
|
lda #$00
|
||||||
|
sta Addr_Mode
|
||||||
|
jsr Get_Val_To_LAC
|
||||||
|
beq @exit
|
||||||
|
lda Addr_Mode
|
||||||
|
+bne Mon_Error ; only 16-bit value allowed
|
||||||
|
|
||||||
|
rts
|
||||||
Reference in new issue
Block a user