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

@@ -329,22 +329,22 @@ MainLoop:
jsr decsp6 ; 3 args
ldy #5
lda OutData+1
sta (sp),y
sta (c_sp),y
dey
lda OutData
sta (sp),y
sta (c_sp),y
dey
lda FSave+1
sta (sp),y
sta (c_sp),y
dey
lda FSave
sta (sp),y
sta (c_sp),y
dey
lda FCount+1
sta (sp),y
sta (c_sp),y
dey
lda FCount
sta (sp),y
sta (c_sp),y
jsr CallOutFunc ; Call the output function
; We're back from out(), or we didn't call it. Check for end of string.

View File

@@ -13,7 +13,7 @@
.import initlib, donelib
.import push0, _main
.import IRQStub, __nmi
.importzp sp
.importzp c_sp
; Linker-generated
.import __CARTSIZE__
@@ -86,8 +86,8 @@ start: sei
; Set up the stack
lda #<(__MAIN_START__ + __MAIN_SIZE__ + __STACKSIZE__)
ldx #>(__MAIN_START__ + __MAIN_SIZE__ + __STACKSIZE__)
sta sp
stx sp+1
sta c_sp
stx c_sp+1
; Call the module constructors.
jsr initlib

View File

@@ -18,7 +18,7 @@
.export memcpy_increment, memcpy_transfer, memcpy_getparams
.import incsp2, popax, popptr1
.importzp sp, ptr1, ptr2, ptr3
.importzp c_sp, ptr1, ptr2, ptr3
; The structure of the transfer instructions
@@ -86,9 +86,9 @@ memcpy_getparams:
; (Direct stack access is six cycles faster [total cycle count].)
iny ; (Y=0 by popptr1, need '1' here) save dest
lda (sp),y ; get high byte
lda (c_sp),y ; get high byte
tax
lda (sp) ; get low byte
lda (c_sp) ; get low byte
sta ptr2
stx ptr2+1
rts ; return dest address (for memmove)