more Kernal reorganization

This commit is contained in:
FeralChild64 committed 2019-10-15 17:55:56 +02:00
1 parent 076a839f1a
commit 8829ec8090
20 files changed
+2

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
The original reason to move PLOT routine into its original position was to provide support for unofficial $E50C address:
- it is well known: https://www.lemon64.com/forum/viewtopic.php?t=3296&amp%3Bstart=15
https://sys64738.org/2019/05/c64-bedtime-coding-eng-printing-08/
- 'Duotris' game calls $E50C during startup screen initialization
+32
View File
@@ -0,0 +1,32 @@
//
// Official Kernal routine, described in:
//
// - [RG64] C64 Programmer's Reference Guide - page 290
// - [CM64] Compute's Mapping the Commodore 64 - page 215
//
// CPU registers that has to be preserved (see [RG64]): none
//
PLOT:
bcs plot_get
// Note: the 'set' part has to start from $E50C, as this is a known address
// - https://www.lemon64.com/forum/viewtopic.php?t=3296&amp%3Bstart=15
// - https://sys64738.org/2019/05/c64-bedtime-coding-eng-printing-08/
// - 'Duotris' game calls $E50C during startup screen initialization
plot_set:
sty PNTR
stx TBLX
jsr screen_calculate_line_pointer
// FALLTROUGH to save one byte on RTS
plot_get:
ldy PNTR
ldx TBLX
rts