From bfb8dd8f9553e72ea92e60b353428a137a718a15 Mon Sep 17 00:00:00 2001 From: cpg Date: Sun, 6 Feb 2011 20:57:14 +0000 Subject: [PATCH] add Antic opcodes (submitted by Christian Krueger) git-svn-id: svn://svn.cc65.org/cc65/trunk@4968 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- asminc/atari.inc | 73 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 70 insertions(+), 3 deletions(-) diff --git a/asminc/atari.inc b/asminc/atari.inc index 135f7d6b4..8d84311be 100644 --- a/asminc/atari.inc +++ b/asminc/atari.inc @@ -1,6 +1,6 @@ ;------------------------------------------------------------------------- ; Atari System Equates -; by Freddy Offenga & Christian Groessler +; by Freddy Offenga, Christian Groessler, and Christian Krueger ; ; References: ; - Atari 400/800 OS rev.B source code, Atari 1979 @@ -1017,7 +1017,7 @@ STMTAB = $88 ;2-byte statement table address STMCUR = $8A ;2-byte current statement pointer STARP = $8C ;2-byte string and array table pointer RUNSTK = $8E ;2-byte runtime stack address -;MEMTOP = $90 ;2-byte top of memory pointer +BMEMTOP = $90 ;2-byte top of memory pointer STOPLN = $BA ;2-byte stopped line number ERRSAVE = $C3 ;1-byte error code PTABW = $C9 ;1-byte tab width @@ -1096,6 +1096,73 @@ MYDOS = 3 NODOS = 255 ;------------------------------------------------------------------------- -; End of atari.inc +; Antic opcodes ;------------------------------------------------------------------------- +; usage example: +; +; ScreenDL: +; .byte DL_BLK8 +; .byte DL_BLK8 +; .byte DL_CHR40x8x1 + DL_LMS + DL_DLI +; .word ScreenAlignment +; .byte DL_BLK1 + DL_DLI +; .byte DL_MAP320x1x1 + DL_LMS +; .word Screen +; +; .repeat 99 +; .byte DL_MAP320x1x1 +; .endrepeat +; .byte DL_MAP320x1x1 + DL_LMS +; .word Screen + 40 * 100 ; 100 lines a 40 byte, 'Screen' has to be aligned correctly! +; .repeat 92 +; .byte DL_MAP320x1x1 +; .endrepeat +; +; .byte DL_JVB + +; absolute instructions (non mode lines) + +DL_JMP = 1 +DL_JVB = 65 + +DL_BLK1 = 0 +DL_BLK2 = 16 +DL_BLK3 = 32 +DL_BLK4 = 48 +DL_BLK5 = 64 +DL_BLK6 = 80 +DL_BLK7 = 96 +DL_BLK8 = 112 + +; absolute instructions (mode lines) + +DL_CHR40x8x1 = 2 ; monochrome, 40 character & 8 scanlines per mode line (GR. 0) +DL_CHR40x10x1 = 3 ; monochrome, 40 character & 10 scanlines per mode line +DL_CHR40x8x4 = 4 ; colour, 40 character & 8 scanlines per mode line (GR. 12) +DL_CHR40x16x4 = 5 ; colour, 40 character & 16 scanlines per mode line (GR. 13) +DL_CHR20x8x2 = 6 ; colour (duochrome per character), 20 character & 8 scanlines per mode line (GR. 1) +DL_CHR20x16x2 = 7 ; colour (duochrome per character), 20 character & 16 scanlines per mode line (GR. 2) + +DL_MAP40x8x4 = 8 ; colour, 40 pixel & 8 scanlines per mode line (GR. 3) +DL_MAP80x4x2 = 9 ; 'duochrome', 80 pixel & 4 scanlines per mode line (GR.4) +DL_MAP80x4x4 = 10 ; colour, 80 pixel & 4 scanlines per mode line (GR.5) +DL_MAP160x2x2 = 11 ; 'duochrome', 160 pixel & 2 scanlines per mode line (GR.6) +DL_MAP160x1x2 = 12 ; 'duochrome', 160 pixel & 1 scanline per mode line (GR.14) +DL_MAP160x2x4 = 13 ; 4 colours, 160 pixel & 2 scanlines per mode line (GR.7) +DL_MAP160x1x4 = 14 ; 4 colours, 160 pixel & 1 scanline per mode line (GR.15) +DL_MAP320x1x1 = 15 ; monochrome, 320 pixel & 1 scanline per mode line (GR.8) + +; modifiers on mode lines... + +DL_HSCROL = 16 +DL_VSCROL = 32 +DL_LMS = 64 + +; general modifier... + +DL_DLI = 128 + +;------------------------------------------------------------------------- +; End of atari.inc +;-------------------------------------------------------------------------