2 ; adapted from Atari version
3 ; Christian Groessler, 2014
5 ; void cputcxy (unsigned char x, unsigned char y, char c);
9 .include "atari5200.inc"
11 .export _cputcxy, _cputc
12 .export plot, cputdirect, putchar
13 .import gotoxy, _mul20
15 .importzp screen_width, screen_height
18 .constructor screen_setup, 26
19 .import screen_setup_20x24
20 screen_setup = screen_setup_20x24
25 jsr gotoxy ; Set cursor, drop x and y
37 cmp #ATEOL ; Atari-EOL?
51 cputdirect: ; accepts screen code
78 jsr _mul20 ; destroys tmp4, carry is cleared
79 adc SAVMSC ; add start of screen memory
86 ; and #$C0 ; without this we are compatible with the old version. user must not try to output a char >= $3F
94 ataint: .byte 64,0,32,96