Commodore 128 Programmer's Reference Manual page 464

Hide thumbs Also See for 128:
Table of Contents

Advertisement

454
COMMODORE 128
;want to call $2000 in bank 1
LDA#1
LDY #$20
LDX #$00
STA $02
STY $03
STX $04
JSR $FF6E
;JSRFAR
LDA $05
;restore status and registers
PHA
LDA $06
LDX $07
LDY $08
PLP
u
16. $FF74 INDFET ;LDA (fetvec),Y from any bank
PREPARATION:
Registers:
Memory:
Flags:
Calls:
RESULTS:
Registers:
Memory:
Flags:
EXAMPLE:
LDA #$00
STA $FA
LDA #$20
STA $FB
LDA #$FA
LDX #$01
LDY #$00
JSR $FF74
BEQ etc
.A = pointer to address
.X = bank (0-15)
.Y = index
setup indirect vector
none
none
.A = data
.X used
none
status valid
;setup to read $2000
;in bank 1
;LDA ($FA,RAM 1),Y
u
INDFET enables applications to read data from any other bank. It sets up
FETVEC ($2AA), calls GETCFG to convert the bank number, and JMPs to code in

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents