Kernel Jump Table

The MEGA65 kernel jump table provides stable addresses you can call to access kernel routines from your program. The table addresses are guaranteed not to change, even if other changes in the ROM change the actual code locations.

Addresses $ff4d-$ff7d are compatible with the Commodore 128 jump table. Addresses $ff80-$fff3 are compatible with the Commodore 64 jump table. Neither C65 nor MEGA65 have added new jump table entries.

Address

ROM jump

Comment

Notes

Address

ROM jump

Comment

Notes

ff4d

jmp spin_spout

setup fast serial port for input or output

 

ff50

jmp close_all

close all logical files for a given device

 

ff53

jmp c64mode

reconfigure system as a c/64 (no return!)

 

ff56

jmp monitor_call

map in Monitor & call it

 

ff59

jmp bootsys

boot alternate system from disk   [910110]

 

ff5c

jmp phoenix

call carts' cold start routines, disk boot loader

 

ff5f

jmp lkupla

search tables for given la

 

ff62

jmp lkupsa

search tables for given sa

 

ff65

jmp swapper

swap to alternate display device   (editor)

 

ff68

jmp pfkey

program function key     (editor)

 

ff6b

jmp setbnk

set bank for load/save/verify/open

 

ff6e

jmp jsr_far

JSR to any bank, RTS to calling bank

 

ff71

jmp jmp_far

JMP to any bank

 

ff74

jmp lda_far

LDA (X),Y from bank Z

 

ff77

jmp sta_far

STA (X),Y to   bank Z

 

ff7a

jmp cmp_far

CMP (X),Y to   bank Z

 

ff7d

jmp primm

print immediate  (always JSR to this routine!)

 

ff81

jmp cint

init screen editor & display chips   (editor)

 

ff84

jmp ioinit

init I/O devices (ports, timers, etc.)

 

ff87

jmp ramtas

initialize RAM for system

 

ff8a

jmp restor

restore vectors to initial system

 

ff8d

jmp vector

change vectors for user

 

ff90

jmp setmsg

control o.s. messages

 

ff93

jmp (isecond)

send sa after listen

 

ff96

jmp (italksa)

send sa after talk

 

ff99

jmp memtop

set/read top of memory

 

ff9c

jmp membot

set/read bottom of memory

 

ff9f

jmp key

scan keyboard      (editor)

 

ffa2

jmp monexit

monitor exit to BASIC (monitor)

 

ffa5

jmp (iacptr)

read a byte from active serial bus talker

 

ffa8

jmp (iciout)

send a byte to active serial bus listener

 

ffab

jmp (iuntalk)

command serial bus device to stop talking

 

ffae

jmp (iunlisten)

command serial bus device to stop listening

 

ffb1

jmp (ilisten)

command serial bus device to listen

 

ffb4

jmp (italk)

command serial bus device to talk

 

ffb7

jmp readss

return I/O status byte

 

ffba

jmp setlfs

set la, fa, sa

 

ffbd

jmp setnam

set length and fn adr

 

ffc0

jmp (iopen)

open logical file

 

ffc3

jmp (iclose)

close logical file

 

ffc6

jmp (ichkin)

open channel in

 

ffc9

jmp (ickout)

open channel out

 

ffcc

jmp (iclrch)

close I/O channel

 

ffcf

jmp (ibasin)

input from channel

 

ffd2

jmp (ibsout)

output to channel

 

ffd5

jmp load

load from file

 

ffd8

jmp save

save to file

 

ffdb

jmp Set_Time

set internal clock

 

ffde

jmp Read_Time

read internal clock

 

ffe1

jmp (istop)

scan stop key

 

ffe4

jmp (igetin)

get char from queue

 

ffe7

jmp (iclall)

clear all logical files (see close_all)

 

ffea

jmp ScanStopKey

(was increment clock) & scan stop key

 

ffed

jmp scrorg

return current screen window size   (editor)

 

fff0

jmp plot

read/set x,y coord     (editor)

 

fff3

jmp iobase

return I/O base