]> git.sur5r.net Git - cc65/blob - libsrc/atari5200/gotoxy.s
Merge remote-tracking branch 'upstream/master' into creativision
[cc65] / libsrc / atari5200 / gotoxy.s
1 ;
2 ; Christian Groessler, 13-Mar-2014
3 ;
4 ; void gotoxy (unsigned char x, unsigned char y);
5 ;
6
7         .include "atari5200.inc"
8
9         .export         gotoxy, _gotoxy
10         .import         popa
11         .import         setcursor
12
13 gotoxy:
14         jsr     popa            ; Get Y
15
16 _gotoxy:                        ; Set the cursor position
17         sta     ROWCRS_5200     ; Set Y
18         jsr     popa            ; Get X
19         sta     COLCRS_5200     ; Set X
20         jmp     setcursor