s19test.asm
来自「该应用软件可以实现大多数单片机的仿真实验」· 汇编 代码 · 共 43 行
ASM
43 行
; Calls the S19LOAD.SUB subroutine for testing it
#listoff
#include 811E2.INC
#liston
Offset equ 0 ;Offset to adjust loading location
#ROM
Start lds #STACKTOP
lda #$0C
sta $102D
clrd
clrx
clry
ldx #Offset
bsr S19
; Now X holds the execution address based on S9 record info
; Jump to code if X non-zero (and no error, Carry set)
bcs Halt ;Error loading, exit
cmpx #Offset ;Check if X = offset (or X = 0)
beq Halt ;If zero difference, don't execute
jmp ,x ;Execute loaded program
Halt cls
sei
stop
bra *-1
AnRTI rti
#mapoff
#include s19load.sub
#mapon
#VECTORS
dw:20 AnRTI
dw Start
end Start
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?