This commit is contained in:
mrdudz
2025-06-23 17:09:06 +02:00
parent 4863a3e29b
commit 5fc15a7a60
204 changed files with 915 additions and 912 deletions

View File

@@ -7,23 +7,23 @@
.export _DbgMemDump
.import addysp1
.import __hextab
.importzp sp, tmp2, tmp3, tmp4, ptr3, ptr4
.importzp c_sp, tmp2, tmp3, tmp4, ptr3, ptr4
_DbgMemDump:
ldy #0
lda (sp),y ; Get length
lda (c_sp),y ; Get length
sta tmp4
iny
lda (sp),y ; Get the string buffer
lda (c_sp),y ; Get the string buffer
sta ptr3
iny
lda (sp),y
lda (c_sp),y
sta ptr3+1
iny
lda (sp),y ; Get the address
lda (c_sp),y ; Get the address
sta ptr4
iny
lda (sp),y
lda (c_sp),y
sta ptr4+1
jsr addysp1 ; Drop the parameters

View File

@@ -36,9 +36,9 @@ DbgBreak:
jsr DbgSwapZP ; Swap stuff
lda #<DbgStack ; Set new stack
sta sp
sta c_sp
lda #>DbgStack
sta sp+1
sta c_sp+1
jsr ResetDbgBreaks ; Reset temporary breakpoints
jsr _DbgEntry ; Call C code
jsr SetDbgBreaks ; Set temporary breakpoints
@@ -61,7 +61,7 @@ DbgStack:
; Swap space for the C temporaries
CTemp:
_DbgCS: .res 2 ; sp
_DbgCS: .res 2 ; c_sp
_DbgHI: .res 2 ; sreg
.res (zpsavespace-4) ; Other stuff
@@ -78,7 +78,7 @@ Swap1: ldx CTemp,y
lda <__ZP_START__,y
sta CTemp,y
txa
sta sp,y
sta c_sp,y
dey
bpl Swap1
rts