From aab7b98c27670dd216ebafb0f8cde89901f88c3f Mon Sep 17 00:00:00 2001 From: Paul Gardner-Stephen Date: Fri, 19 Apr 2019 21:03:53 +0930 Subject: [PATCH] fix some bugs --- c64/kernal/chrout.s | 5 +---- c64/kernal/set_pointer_to_current_screen_line.s | 7 ++++--- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/c64/kernal/chrout.s b/c64/kernal/chrout.s index 371cc232..18842a3d 100644 --- a/c64/kernal/chrout.s +++ b/c64/kernal/chrout.s @@ -1,9 +1,6 @@ ; Function defined on pp272-273 of C64 Programmers Reference Guide chrout: ;; Crude implementation of character output - sta $0400 - inc $0401 - jmp chrout ;; Write character on the screen ldy current_screen_x @@ -13,7 +10,7 @@ chrout: ;; to insert a 2nd line in this logical line. ;; (eg Compute's Mapping the 64 p41) ldx current_screen_y - iny current_screen_x + iny sty current_screen_x cpy #40 beq screen_grow_logical_line diff --git a/c64/kernal/set_pointer_to_current_screen_line.s b/c64/kernal/set_pointer_to_current_screen_line.s index 37089d31..1dbb7349 100644 --- a/c64/kernal/set_pointer_to_current_screen_line.s +++ b/c64/kernal/set_pointer_to_current_screen_line.s @@ -15,12 +15,13 @@ set_pointer_to_current_screen_line: sptcsl_l2: ;; XXX - Should we read the columns per line from ;; somewhere? - lda #<40 + ldy #<40 ;; Double line length if line is linked - bit screen_line_link_table,x + lda screen_line_link_table,x bpl sptcsl_l1 - asl + ldy #<80 sptcsl_l1: + tya clc adc current_screen_line_ptr+0 lda current_screen_line_ptr+1