We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2b61399 commit f5671cdCopy full SHA for f5671cd
1 file changed
src/interp/a5200/putchar.asm
@@ -58,16 +58,14 @@ no_eol:
58
59
; Convert character from ATASCII to screen codes
60
asl
61
- tax ; X holds the value without high bit
62
- ror
63
- cpx #$C0 ; chars >= $60 don't need conversion
64
- bcs conv_ok
65
- cpx #$40 ; chars >= $20 needs -$20 (upper case and numbers)
66
- bcs normal_char
67
- adc #$61 ; Chars from $00 to $1F, add $40 (+$21, subtracted bellow)
68
-normal_char:
69
- sbc #$20 ; Chars from $20 to $5F, subtract $20
+ php
+ sbc #$3F
+ bpl conv_ok
+ eor #$40
70
conv_ok:
+ plp
+ ror
+
71
pha ; Store A
72
73
; Calculate coordinates - only valid for text modes
0 commit comments