User Tools

Site Tools


notes:atari:antic

Atari ANTIC

Hardware registers and memory locations related to ANTIC ($D400 to $D5FF).

Registers

; hardware registers
DMACTL  = $D400 ; DMA control
PMBASE  = $D407 ; MSB of the player/missile base address
CHBASE  = $D409 ; MSB of the character set (CHaracter BASe)
WSYNC   = $D40A ; wait for horizontal synchronization
VCOUNT  = $D40B ; vertical counter
NMIEN   = $D40E ; NMI enable/disable
NMIST   = $D40F ; NMI status indicating the interrupt source
 
; shadow registers
DMACTLS = $022F ; DMA control

Table

Register Name Register Hex / Dec Shadow Name Shadow Hex / Dec
DMACTL $D400 54272 DMACTLS (=SDMACTL) $022F 559
PMBASE $D407 54279
CHBASE $D409 54281
WSYNC $D40A 54282
VCOUNT $D40B 54283
NMIEN $D40E 54286
NMIST $D40F 54287

Details

DMACTL ($D400)

DMA control:

  • defines the playfield size
  • enables player/missile graphics
  • controls the player size resolution
  • enables DMA for fetching the display list instructions
  • the default value 34 = $22 = $02 (standard playfield) + $20 (enable DMA for fetching instructions)
  • setting DMACTL=0 turns off ANTIC and speeds up processing by 30%
7 6 5 4 3 2 1 0
- - - - - - 0 0 No playfield
- - - - - - 0 1 Narrow playfield
- - - - - - 1 0 Standard playfield (default)
- - - - - - 1 1 Wide playfield
- - - - - 1 - - Enable missle DMA
- - - - 1 - - - Enable player DMA
- - - 1 - - - - One line player resolution
- - - 0 - - - - Two-line player resolution (default)
- - 1 - - - - - Enable DMA for fetching the display list instructions (default)

The playfield is the area of the screen used to display text and graphics:

Playfield Width in color clocks Width in characters
Narrow 128 color clocks 32 characters
Standard playfield 160 color clocks 40 characters
Wide 192 color clocks 48 characters

Display the display list in GRAPHICS 0:

10 GRAPHICS 0
20 DL=PEEK(560)+256*PEEK(561)
30 FOR I=DL TO DL+31
40 PRINT PEEK(I);" ";
50 NEXT I

NMIST ($D40F)

  • if bit7=1, the ANTIC interrupt occured; if bit7=0, the vertical blank interrupt occured

Acronyms

  • DMA - Direct Memory Access
notes/atari/antic.txt · Last modified: 2017/12/14 by leszek