vectors at #300 are now initialized

This commit is contained in:
FeralChild64 committed 2019-09-27 20:06:23 +02:00
1 parent 72a60958e9
commit 2abda0944b
4 files changed
+110 -12

No files matched your search

+6 -6
View File
@@ -193,12 +193,12 @@
// [!] XXX document $2A7-$2FF usage // [!] XXX document $2A7-$2FF usage
// BASIC vectors // BASIC vectors
.label IERROR = $300 // $300-$301 -- NOT IMPLEMENTED -- .label IERROR = $300 // $300-$301
.label IMAIN = $302 // $302-$303 -- NOT IMPLEMENTED -- .label IMAIN = $302 // $302-$303
.label ICRNCH = $304 // $304-$305 -- NOT IMPLEMENTED -- .label ICRNCH = $304 // $304-$305
.label IQPLOP = $306 // $306-$307 -- NOT IMPLEMENTED -- .label IQPLOP = $306 // $306-$307
.label IGONE = $308 // $308-$309 -- NOT IMPLEMENTED -- .label IGONE = $308 // $308-$309
.label IEVAL = $30A // $30A-$30B -- NOT IMPLEMENTED -- .label IEVAL = $30A // $30A-$30B
.label SAREG = $30C // .A storage, for SYS call .label SAREG = $30C // .A storage, for SYS call
.label SXREG = $30D // .X storage, for SYS call .label SXREG = $30D // .X storage, for SYS call
+9 -1
View File
@@ -1,7 +1,15 @@
// BASIC Cold start entry point // BASIC Cold start entry point
// Compute's Mapping the 64 p211 // Compute's Mapping the 64 p211
basic_cold_start: basic_cold_start:
// Setup vectors at $300
ldy #$0B
!:
lda basic_vector_defaults, y
sta IERROR, y
dey
bpl !-
// Print startup banner // Print startup banner
jsr printf // XXX don't use printf, keep it for debug purposes only jsr printf // XXX don't use printf, keep it for debug purposes only
+16
View File
@@ -0,0 +1,16 @@
//
// Default values for BASIC vectors - described in:
//
// - [RG64] C64 Programmer's Reference Guide - pages 68-70
// - [CM64] Compute's Mapping the Commodore 64 - page 318
//
basic_vector_defaults:
.word ERROR // IERROR
.word MAIN // IMAIN
.word CHRNCH // ICHRNCH
.word QPLOP // IQPLOP
.word GONE // IGONE
.word EVAL // IEVAL
+79 -5
View File
@@ -1,82 +1,156 @@
//
// Default handler for all not-yet-implemented commands // Default handler for all not-yet-implemented commands
//
// Note: NOPs are here just to make debugging easier!
//
cmd_for: cmd_for:
nop
cmd_next: cmd_next:
nop
cmd_data: cmd_data:
nop
cmd_inputhash: cmd_inputhash:
nop
cmd_input: cmd_input:
nop
cmd_dim: cmd_dim:
nop
cmd_read: cmd_read:
nop
cmd_let: cmd_let:
nop
cmd_if: cmd_if:
nop
cmd_restore: cmd_restore:
nop
cmd_gosub: cmd_gosub:
nop
cmd_return: cmd_return:
nop
// $90-$9F // $90-$9F
cmd_on: cmd_on:
nop
cmd_wait: cmd_wait:
nop
cmd_save: cmd_save:
nop
cmd_verify: cmd_verify:
nop
cmd_def: cmd_def:
nop
cmd_poke: cmd_poke:
nop
cmd_printhash: cmd_printhash:
nop
cmd_print: cmd_print:
nop
cmd_cont: cmd_cont:
nop
cmd_cmd: cmd_cmd:
nop
cmd_open: cmd_open:
nop
// $A0-$AF // $A0-$AF
cmd_close: cmd_close:
nop
cmd_get: cmd_get:
nop
cmd_tab: cmd_tab:
nop
cmd_to: cmd_to:
nop
cmd_fn: cmd_fn:
nop
cmd_spc: cmd_spc:
nop
cmd_then: cmd_then:
nop
cmd_not: cmd_not:
nop
cmd_step: cmd_step:
nop
cmd_plus: cmd_plus:
nop
cmd_minus: cmd_minus:
nop
cmd_mult: cmd_mult:
nop
cmd_div: cmd_div:
nop
cmd_exponent: cmd_exponent:
nop
cmd_and: cmd_and:
nop
// $B0-$BF // $B0-$BF
cmd_or: cmd_or:
nop
cmd_greater: cmd_greater:
nop
cmd_equal: cmd_equal:
nop
cmd_less: cmd_less:
nop
cmd_sgn: cmd_sgn:
nop
cmd_int: cmd_int:
nop
cmd_abs: cmd_abs:
nop
cmd_usr: cmd_usr:
nop
cmd_fre: cmd_fre:
nop
cmd_pos: cmd_pos:
nop
cmd_sqr: cmd_sqr:
nop
cmd_rnd: cmd_rnd:
nop
cmd_log: cmd_log:
nop
cmd_exp: cmd_exp:
nop
cmd_cos: cmd_cos:
nop
cmd_sin: cmd_sin:
nop
// $C0-$CF // $C0-$CF
cmd_tan: cmd_tan:
nop
cmd_atn: cmd_atn:
nop
cmd_peek: cmd_peek:
nop
cmd_len: cmd_len:
nop
cmd_str: cmd_str:
nop
cmd_val: cmd_val:
nop
cmd_asc: cmd_asc:
nop
cmd_chr: cmd_chr:
nop
cmd_left: cmd_left:
nop
cmd_right: cmd_right:
nop
cmd_mid: cmd_mid:
nop
cmd_go: cmd_go:
nop
// Undefined tokens // Undefined tokens
cmd_unimplemented: cmd_unimplemented:
jmp do_NOT_IMPLEMENTED_error jmp do_NOT_IMPLEMENTED_error