home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Transactor
/
Transactor_20_1987_Transactor_Publishing.d64
/
memlane3
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2023-02-26
|
714b
|
27 lines
100 ;.y is saved in 'holdy'
110 ; and loaded with the low byte of the Kernal routine
120 ; prior to calling 'farkernal'
130 ;
140 farkernal =*
150 sty kernrtn ;self mod jsr
160 ldy #0
170 sty $ff00 ;bank 15
180 sty $d507 ;your own z page, mr. kernal sir.
190 ldy holdy ;in case it's needed
200 jsr $ffff ;call routine
210 kernrtn =*-2
220 php ;save status
230 pha ;and .a
240 lda #myzpg ;my zero page back
250 sta $d507
260 sta $ff02 ;latch to bank 1
270 pla ;remember .a
280 plp ;and status
290 rts
300 ;
310 ;" [200]ere is how [198][193][210][203][197][210][206][193][204] would be used to [208][210][201][206][212] from [194]ank 1:
320 [153] [178][172]
330 sty holdy ;[148] .y
340 ldy #$d2 ;[179]$ffd2
350 jmp farkernal