mirror of
https://github.com/cc65/cc65.git
synced 2024-10-17 02:26:16 +00:00
Remove unnecessary commented code.
This commit is contained in:
parent
0a6afb59c0
commit
12ca22c265
@ -1,10 +1,10 @@
|
|||||||
;
|
;
|
||||||
; Ullrich von Bassewitz, 06.08.1998
|
; cputc/cputcxy for Challenger 1P
|
||||||
|
; Based on PET/CBM implementation
|
||||||
;
|
;
|
||||||
; void cputcxy (unsigned char x, unsigned char y, char c);
|
; void cputcxy (unsigned char x, unsigned char y, char c);
|
||||||
; void cputc (char c);
|
; void cputc (char c);
|
||||||
;
|
;
|
||||||
|
|
||||||
.export _cputcxy, _cputc, cputdirect, putchar
|
.export _cputcxy, _cputc, cputdirect, putchar
|
||||||
.export newline, plot
|
.export newline, plot
|
||||||
.import popa, _gotoxy
|
.import popa, _gotoxy
|
||||||
@ -29,18 +29,6 @@ _cputc: cmp #$0A ; CR?
|
|||||||
L1: cmp #$0D ; LF?
|
L1: cmp #$0D ; LF?
|
||||||
beq newline ; Recalculate pointers
|
beq newline ; Recalculate pointers
|
||||||
|
|
||||||
; Printable char of some sort
|
|
||||||
|
|
||||||
; cmp #' '
|
|
||||||
; bcc cputdirect ; Other control char < 0x20
|
|
||||||
; tay
|
|
||||||
; bmi L10
|
|
||||||
; cmp #$60
|
|
||||||
; bcc L2
|
|
||||||
; and #$DF
|
|
||||||
; bne cputdirect ; Branch always
|
|
||||||
;L2: and #$3F
|
|
||||||
|
|
||||||
cputdirect:
|
cputdirect:
|
||||||
jsr putchar ; Write the character to the screen
|
jsr putchar ; Write the character to the screen
|
||||||
|
|
||||||
@ -65,39 +53,17 @@ newline:
|
|||||||
L4: inc CURS_Y
|
L4: inc CURS_Y
|
||||||
rts
|
rts
|
||||||
|
|
||||||
; Handle character if high bit set
|
|
||||||
|
|
||||||
; L10: and #$7F
|
|
||||||
; cmp #$7E ; PI?
|
|
||||||
; bne L11
|
|
||||||
; lda #$5E ; Load screen code for PI
|
|
||||||
; bne cputdirect
|
|
||||||
; L11: ora #$40
|
|
||||||
; bne cputdirect
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
; Set cursor position, calculate RAM pointers
|
|
||||||
|
|
||||||
plot: ldy CURS_Y
|
plot: ldy CURS_Y
|
||||||
lda ScrLo,y
|
lda ScrLo,y
|
||||||
sta SCREEN_PTR
|
sta SCREEN_PTR
|
||||||
lda ScrHi,y
|
lda ScrHi,y
|
||||||
; ldy SCR_LINELEN
|
|
||||||
; cpy #40+1
|
|
||||||
; bcc @L1
|
|
||||||
; asl SCREEN_PTR ; 80 column mode
|
|
||||||
; rol a
|
|
||||||
;@L1: ora #$80 ; Screen at $8000
|
|
||||||
sta SCREEN_PTR+1
|
sta SCREEN_PTR+1
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
|
||||||
; Write one character to the screen without doing anything else, return X
|
; Write one character to the screen without doing anything else, return X
|
||||||
; position in Y
|
; position in Y
|
||||||
|
|
||||||
putchar:
|
putchar:
|
||||||
; ora RVS ; Set revers bit
|
|
||||||
ldy CURS_X
|
ldy CURS_X
|
||||||
sta (SCREEN_PTR),y ; Set char
|
sta (SCREEN_PTR),y ; Set char
|
||||||
rts
|
rts
|
||||||
|
Loading…
Reference in New Issue
Block a user