2000-05-28 13:40:48 +00:00
|
|
|
;
|
|
|
|
; Ullrich von Bassewitz, 03.06.1999
|
|
|
|
;
|
2001-10-10 20:35:07 +00:00
|
|
|
; unsigned int __fastcall__ cbm_k_load (unsigned char flag, unsigned addr);
|
2000-05-28 13:40:48 +00:00
|
|
|
;
|
|
|
|
|
2018-07-03 22:47:42 +03:00
|
|
|
.include "cbm.inc"
|
2018-07-04 17:40:28 +03:00
|
|
|
|
2013-05-09 13:56:54 +02:00
|
|
|
.export _cbm_k_load
|
2022-08-28 21:52:53 +02:00
|
|
|
.import ___oserror
|
2013-05-09 13:56:54 +02:00
|
|
|
.import popa
|
|
|
|
.importzp ptr1
|
2000-05-28 13:40:48 +00:00
|
|
|
|
2001-03-13 22:48:19 +00:00
|
|
|
_cbm_k_load:
|
2013-05-09 13:56:54 +02:00
|
|
|
sta ptr1
|
|
|
|
stx ptr1+1
|
|
|
|
jsr popa ; get flag
|
|
|
|
ldx ptr1
|
|
|
|
ldy ptr1+1
|
|
|
|
jsr LOAD
|
|
|
|
bcc @Ok
|
2022-08-28 21:52:53 +02:00
|
|
|
sta ___oserror
|
2001-10-10 20:35:07 +00:00
|
|
|
ldx ptr1
|
|
|
|
ldy ptr1+1
|
|
|
|
@Ok: txa
|
|
|
|
pha
|
|
|
|
tya
|
|
|
|
tax
|
|
|
|
pla
|
|
|
|
rts
|