Memory Map
What follows in this section is a list of important locations in the silicon memory of your ATARI 400 or 800. This sequential list of memory locations is called a memory map. The memory inside any ATARI is divided into sections called pages. Each page contains 256 bytes (locations). In a 64K machine there are 256 pages of memory. Memory is further divided into RAM and ROM locations. The ROM cannot be changed by the program. It is created at the factory and contains those values and programs always available on any ATARI. The RAM memory addressees 0 - 1012 can be, and are altered by running programs. It is these low memory addresses that are described here. To adequately identify these RAM locations, our format gives the decimal value of the location, the equivalent hexadecimal (base 16) value, the number of contiguous locations serving the specified function, the name used in the Operating System listing published by Atari, and a description of the function. For example:
783 $30F 1 CASFLG Cassette mode indicator.
This means that location 783 (30F in hexidecimal) uses one byte for the function called CASFLG, and is the cassette mode indicator.
NOTE: Hexidecimal numbers are preceeded by a dollar sign ($). This notation is arbitary but is the consensus method of indicating base 16 numbers.
The low memory locations that follow are used by the Operating System for housekeeping functions. Information such as location of Player/Missile data, screen colors, timer values, interrupt vectors, display list pointers and almost any other important information needed by the system to operate is stored here.
Figure 1 shows the gross memory map. This should give you some idea of where BASIC resides in memory, what part of memory is used and unused, etc.
Not all of the 65,536 possible memory locations are described, nor need to be. Most of memory is left "free" for the user. If you have 16K memory, your ATARI has RAM locations 0 through 16,383 available. Then accessible memory jumps to the locations reserved for cartridges, such as BASIC, from 40960 through 49151, and then to high memory where the Operating System's ROM locations are found (See Figure 1).
Many low memory RAM locations are initialized by the Operating System in ROM when the computer is turned on. These values govern execution of user programs and are important for programmers to know. Additional information about memory is found in De Re Atari, the Atari Technical User Notes, (available from Atari Program Exchange), and in Mapping the ATARI, from COMPUTE! Books.
Page Zero | |
---|---|
1 $D 2 LINZBS | May be used to store VBLANK timer. |
2 $2 2 CASINI | If cassette booted successfully during powerup then JSR thru here. |
4 $4 2 RAMLO | Ram pointer for memory test used on powerup. |
6 $6 1 TRAMSZ | Temporary register for RAM size. |
7 $7 1 TSTDAT | RAM test data register. |
8 $8 1 WARMST | Warmstart flag set equal to 1 when S/RESET pushed. When set equal to 0 then powerup retry. |
9 $9 1 BOOT | Boot flag success indicator. When equal to 1 then successful disk boot. When equal to 2 then successful cassette boot. |
10 $A 2 DOSVEC | Disk software start vector. |
12 $C 2 DOSINI | Used to store address of initialization of application upon DOS boot. JSR indirect thru here to initialize application. |
14 $E 2 APPMHI | Contains highest address of RAM needed by user. Screen handler opens S: only if no RAM needed below this address. |
16 $10 1 POKMSK | IRQ service uses and alters POKMSK. These are POKEY interrupts. Shadow for IRQEN[$D20E]. |
bit 7 = 1 Break key interrupt enable. | |
bit 6 = 1 Other key interrupt enable. | |
bit 5 = 1 Serial input data ready interrupt enable. | |
bit 4 = 1 Serial output data needed interrupt enable. | |
bit 3 = 1 Serial out finished interrupt enable. | |
bit 2 = 1 Timer 4 interrupt enable. | |
bit 1 = 1 Timer 1 interrupt enable. | |
17 $11 1 BRKKEY | This is initalized to 1 by OS (1 =no break key pressed). Monitored by keyboard, also screen editor. Break during l/O returns status of $80. This is set to 0 when break key is pressed. |
18 $12 3 RTCLOK | Updated every Vblank interrupt (1/60 Sec.) Called frame counter, initialized to 0 and overflows to 0. The least sienificant byte of counter is $12 and it uses 16 msec units. |
21 $15 2 BUFADR | Indirect buffer address register. Used as a temporary Page Zero pointer to current disk buffer. |
23 $17 1 ICCOMT | Command for CIO vector. Used to find correct vector to the handler routine. |
24 $1B 2 DSKFMS | Disk file manager pointer. Used as vector to FMS. |
26 $1A 2 DSKUTL | Disk utilities pointer. Points to a buffer for utilities package. |
28 $1C 1 PTIMOT | Printer timeout every printer status request. Typical timeout for the 825 is 5 seconds. Initialized to 30 sec. |
29 $1D 1 PBPNT | Print buffer pointer, index into printer buffer ranges from 0 to value of PBUFSZ. |
30 $1E 1 PBUFSZ | Print buffer size of printer record for current mode. normal=40 bytes double width=20 bytes sideways=29 bytes (Atari 820 printer) status =4 |
31 $1F 1 PTEMP | Printer handler uses this temp register to save value of character to output to printer. |
32 $20 1 ZIOCB | Handler index number into the device name table for currently opened file. Set to 255 if no file opened. |
33 $21 1 ICDNOZ | Device # (DRIVE #). Initialized to 1. |
34 $22 1 ICCOMZ | Command code. |
35 $23 1 ICSTAZ | Buffer address for data transfer. |
36 $24 2 ICBALZ | Buffer address for data transfer. |
38 $26 2 ICPTLZ | Put byte routine (address -1) set by OS. |
40 $28 2 ICBLIZ | Buffer length byte count used by PUT and GET commands. |
42 $2A 2 ICAZIZ | Auxiliary information first byte used in OPEN to speci* type of file access. |
43 $2B 1 ICAX2Z | Auxiliary information second byte. CIO working variables. |
44 $2C 2 ICSPF!Z | Spare bytes local CIO use. |
46 $2E 1 ICSPRZ | IOCB Number multiplied by 16. |
47 $2F 1 CIOCHP | Character byte for current operation. |
48 $30 1 STATUS | Internal status storage. |
49 $31 1 CHKSUM | Single byte sum with carry to least significant bit. |
50 $32 2 BUFF!LO | Pointer to data buffer transmitted during I/O operation. |
52 $34 2 BFENLO | Next byte past end of data buffer. |
54 $36 1 CRETRY | Number of command frame retries. Default is 13. |
55 $37 1 DPETRY | Number of device retries. Default is one. |
56 $38 1 BUFPFL | Buffer full flag. (255 indicates full). |
57 $39 1 BECVDN | Receive done flag. (255 indicates done). |
58 $3A 1 XMTDON | Transmission done flag. (255 indicates done). |
59 $3B 1 CHKSNT | Checksum sent flag. (255 indicates done). |
60 $3C 1 NOCKSM | No checksum follows data flag. Zero indicates checksum follows transmission. |
61 $3D 1 BPTR | Cassette record data index into data portion of record being read or written. Values range 0 to current value BLIMI [$28A]. When BPTR=BLIM then buffer CASBOFF [$3FD] is empty if reading or full if writing |
62 $3E 1 FTYPE | Interecord gap type. Copy of ICAX2Z from open command. (0 indicates continuous gaps; non-zero indicates normal gaps.) |
63 $3F 1 FEOF | Cassette end of file flag used by cassette handler to indicate end of file. |
64 $40 1 FREQ | Beep count. Retain and count number of beeps requested of beep routine by cassette handler during open processing; one beep for play, two for record. |
65 $41 1 SOUNDR | Noisy I/O flag, when l/O is done buzzer sounds. POKE 0 and it won't buzz. |
66 $42 1 CRITIC | Defines critical section (if non-zero) checked on NMI process after stage 1 processed. |
67 $43 7 FMSZPO | Disk file manager zero page. |
74 $4A 1 CKEY | Cassette boot request flag on powerup (coldstart). Start key checked, if pressed then CKEY is set. |
75 $4B 1 CASSBT | Cassette boot flag. |
76 $4C 1 DSTAT | Display status used by display handler. |
77 $4D 1 ATRACT | Attract flag set to 0 by IRQ whenever a key is pressed. Incremented every 4 seconds by stage 1 Vblank. When value is < 127 then value is set to $FE until attract mode is terminated. |
7B $4E 1 DRKMSK | Dark attract mask=$FE when attract mode inactive. |
79 $4F 1 COLRSH | Attract color shifter XOR'd with playfield colors. At stage 2 Vblank color registers are XOR'd with COLRSH and DRKMSK then sent to hardware color registers. When attract inactive COLRSH=0 and DRKMSK=$F6 reducing luminance 50% and COLRSH =RTCLOCK + 1 affecting color change every 256/60=4.1 sec. |
B0 $50 1 TEMP | Used by display handler in moving data to and from screen. |
B1 $51 1 HOLD1 | Same as [$50]. When BASIC in use these 2 locations called LOMEM and point to 256 byte buffer at end of OS. RAM used to tokenize one line of BASIC. |
82 $52 1 LMARGN | Column of left margin of text screen, initialized to 2. |
83 $53 1 RMARGN | Column of right margin of text screen initialized to 39. Margins are user alterable. Ignored in every mode but 0. |
84 $54 1 ROWCRS | Display row number used in graphics screen and mode 0. Range 0 -191. This location and COLCRS define the cursor location for the next data element to be read/written to main screen segment. |
85 $55 2 COLCRS | Display column number used in graphics and mode 0 (lobyte). Range 0 - 319 (hibyte). Home position is 0,0 for both graphics and text. |
87 $57 1 DINDEX | Display mode current screen mode obtained from low order 4 bits of most recent open AUX1 byte. |
88 $58 2 SAVMSC | Lowest address of display memory this location corresponds to the upper left corner of screen. |
90 $5A 1 OLDROW | These next 3 locations are updated from ROWCRS and COLCRS before every operation. This location is used by DRAWTO and X10 to determine starting row. |
91 $5B 2 OLDCOL | These variables used only in draw and fill commands. |
93 $5D 1 OLDCHR | Retains value of character under visible text cursor. Used to restore character after cursor moves. |
94 $5E 2 OLDADR | Retains memory address of current visible text cursor location. Used in conjunction with OLDCHR to restore character value after cursor moves. |
96 $60 1 NEWROW | Indicates row location that the DRAWTO and X10 fill routine will use. |
97 $61 2 NEWCOL | Indicates column DRAWTO and X10 will go. |
99 $63 1 LOGCOL | Points at cursor position in logical line. A logical line can contain up to 3 physical lines. This variable is used by display handler and ranges from 0 to 119. |
100 $64 2 ADRESS | Temporary storage holds contents of SAVMSC [$58] |
102 $66 2 ML TTMP | OPNTMP first byte used in open as temporary storage. |
104 $68 2 SAVADR | Temporary storage. |
106 $6A 1 RAMTOP | RAM size defined by power on logic. This value is given in pages (page = 256 bytes of memory). |
107 $6B 1 BUFCNT | Screen editor current logical line size. |
108 $6C 2 BUFSTB | Editor low byte. |
110 $6E 1 BITMSK | Used in bit mapping routines by OS display handler. |
111 $6F 1 SHFAMT | Pixel justification. |
112 $70 2 ROWAC | Control for row and column point plotting. |
114 $722 COLAC | Controls column point plotting. |
116 $74 2 ENDPT | Contains larger of DELTAR and DELTAC used in conjunction with ROWAC/COLAC to control plotting of line points. |
118 $76 1 DELTAFI | Contains absolute value of NEWROW minus ROWCRS. |
119 $77 2 DELTA C | Contains absolute value NEWCOL minus COLCRS. These values and ROWINC and COLINC define slope of line to be drawn. |
121 $79 1 ROWINC | Row increment + 1 or -1. |
122 $7A 1 COLINC | Column increment + 1 or - 1. |
123 $7B 1 SWPFLG | Split screen cursor control. |
124 $7C 1 HOLDCH | Character moved here before control and shift logic processed. |
125 $7D 1 INSDAT | Temporary storage used by display handler. |
126 $7E 2 COUNTFI | Initially contains larger of DELTAR and DELTAC which is number of iterations to generate a line. This value decremented after every point is plotted. When=0 then line is finished. |
128 $80 2 LOMEM | This points to a 256 byte buffer used to tokenize one line of BASIC. This buffer is located at the end of the O.S.RAM. |
130 $82 2 VNTP | Points to list of all variable names used in a program. Each name is stored in the order entered. Maximum of 128 names. |
132 $84 2 VNTD | Points to end of variable name table. Points to a zero byte when all 128 names not used. |
134 $86 2 VVTP | Points to variable value table. Eight bytes allocated for each variable in name table. |
136 $88 2 STMTAB | Points to statement table which contains the tokenized BASIC statements. Also the immediate mode lines. |
138 $8A 2 STMCUR | The BASIC interpreter uses this pointer to access the tokens within a line of the statement table. |
140 $8C 2 STARP | Points to the block containing all the string and array data. Memory is reserved and enlarged whenever a dimension statement is encountered. Strings are stored one byte (ATASCII) per character. Arrays are stored as six byte BCD (Binary Coded Decimal) per element. |
142 S8E 2 RUNSTK | Points to the software run time stack. The stack maintains GOSUB and FOR/NEXT entries. The POP statement affects this stack. |
144 $90 2 MEMTOP | Points to the end of the user program. The FRE function returns the value calculated by subtracting the contents of this location from the contents of HIMEM at $2E5 and $2E6. Don't confuse this MEMTOP with the O.S. variable of the same name at $2E5. |
The remainder of Page Zero is used by BASIC cartridge, floating point routines and assembler cartridges.
Page One is the stack area and is not available for use by programmers.
Page Two | |
---|---|
512 $200 2 VDSLST | Initialized to [$E7B3] if NMI interrupt occurred and it was caused by a DLI then JMP thru here. Since the OS does not use DLIs this is initialized to point to an RTI. |
514 S202 2 VPRCED | Initialized to [$E7B2] if IRQ interrupt occurred due to serial I/O bus proceed line then JMP thru here. |
516 $204 2 VINTER | Initialized to [$E7B2] if IRQ interrupt due to serial I/O bus interrupt then JMP thru here. |
518 S206 2 VBREAK | Initialized to [$E7B2] if IRQ interrupt due to 6502 BRK instruction execution then JMP thru here. |
520 $208 2 VKEYBD | Initialized to [$FFBE] if IRQ interrupt due to keypress then JMP thru here to keyboard handler. |
522 $20A 2 VSERIN | Initialized to [$EB11] if IRQ interrupt due to I/O input ready then JMP thru here. |
524 $20C 2 VSEROR | Initialized to [$EA90] if IRQ interrupt due to I/O bus output ready then JMP thru here. |
526 $20E 2 VSEROC | Initialized to [$EAD1] if IRQ interrupt due to I/O bus output complete then JMP thru here. |
528 $210 2 VTIMR1 | POKEY timer 1 interrupt vector. |
530 $212 2 VTIMR2 | POKEY timer 2 interrupt vector. |
532 $214 2 VTIMR4 | POKEY timer 4 interrupt vector. |
534 $216 2 WMIRQ | Initialized to [$E6F6] if IRQ interrupt occurs then JMP thru here to determine cause. |
536 $218 2 CDTMV1 | SIO timeout decremented at every VBLANK stage 1 when this location counts down to 0 then JSR thru CDTMA1 [$226]. |
538 $21A 2 CDTMV2 | Timer decremented at almost every VBLANK subject to critical section test (stage 2 process). |
540 $21C 2 CDTMV3 | Timer decremented at almost every VBLANK subject to critical section test (stage 2 process). |
542 $21E 2 CDTMV4 | Timer same as 2 & 3. |
544 $220 2 DCTMV5 | Timer same as 2,3 & 4. 3,4,5 set flags CDTMF3=$22A CDTMF4=$22C and CDTMV5=$22E when they equal zero. |
546 $222 2 VVBLKI | Initialized to [$E701] stage 1 vertical blank vector NMI interrupt. |
548 $224 2 VVBLKD | Initialized to [$E93E] system return from interrupt. |
550 $226 2 CD TMA 1 | SIO timeout vector. When CDTMV1 [$218] times out it vectors through here. |
552 $228 2 CDTMA2 | NO SYSTEM FUNCTION. Available to user enter address of routine to be executed at timer count down to 0. |
554 $22A 1 CDTMF3 | Byte flag set when CDTMV3 [$21C,21D] counts down to 0. |
555 $22B 1 SRTIMR | Software repeat timer, controlled by IRQ device routine, establishes initial i/2 second delay before key will repeat. Stage 2 Vblank establishes 1/10 second repeat rate. Decrements timer, implements auto repeat logic. |
556 $22C 1 CDTMF4 | Byte flag set when CDTMV4 [$21E] counts down to 0. |
557 $22D 1 INTEMP | Used by SETVBL routine. |
558 $22E 1 CDTMF5 | Byte flag set when CDTMV5 [$220] counts to 0. |
559 $22F 1 SMDCTL | Shadow for DMACTL [$D400] default value $22. bit 5 = 1 enable Display List instruction fetch DMA. bit 4 = 1 enable 1 1ine P/M resolution. =0 enable 2 line P/M resolution. bit 3 = 1 enable Player DMA. bit 2 = 1 enable Missile DMA. bit 1,0=0 0 no Playfield DMA. =0 1 narrow PlayLield DMA 128 color clocks. = 1 0 standard Playfield DMA 160 clocks. = 1 1 wide PlayEield DMA 192 clocks. |
560 $230 2 SDLSTL | Shadow for DLISTL [$D402]. This location initialized to Start of Display List. |
562 $232 1 SSKCTL | Shadow for SKCTL [$D20F]. bit 7 = 1 force break serial output to 0. bit 6,4=serial port mode control. bit 3 = 1 serial output transmitted as 2-tone instead of logic true/false. bit 2 = 1 pot counter completes within 2 scan lines instead of 1 frame time. bit 1 = 1 enable keyboard scanning circuit. |
563 $233 1 SPARE | NO OPERATING SYSTEM FUNCTION. |
564 $234 1 LPENH | Light pen horizontal value shadow for [$D40C]. Value range 0-227 wrap to 0 at right edge of standard width screen. |
565 $235 1 LPENV | Light pen verticl value shadow for [$D40D]. Value same as VCOUNT 2 line resoluton. Both pen values modified if any joystick trigger lines pulled low. |
566 $236 4 SPARE | NO OPERATING SYSTEM FUNCTION.D. number. |
570 $23A 1 CDEVIC | SIO bus I.D. number |
571 $23B 1 CCOMND | SIO bus command code. |
572 $23C 1 CAUXI | SIO auxiliary byte loaded from location 778. |
573 $23D 1 CAUX2 | SIO command auxiliary byte loaded from location 779. |
574 $23E 1 TEMP | Receives one-byte responses from serial bus controllers. |
575 $23F 1 ERRFLG | SIO error flag. Indicates any device error except timeout errors. |
576 $240 1 DFLAGS | Disk flags from sector 1, contains value of first byte of boot file. |
577 $241 1 DBSECT | Number of disk boot sectors. |
578 $242 2 BOOTAD | Address where disk boot loader will be put. |
580 $244 1 COLDST | Coldstart flag when = 1 then powerup in progress. When = 0 then S/RESET in progress. If set = 1 during normal program execution then S/RESET will act like powerup giving some protection. |
581 $245 1 SMRE | NO OPERATING SYSTEM FUNCTION. |
582 $246 1 DSKTIM | Disk timeout register. |
583 $247 40 LINBUF | Forty byte character line buffer used to temporarily buffer one physical line of text when screen editor is moving screen data. |
623 $26F 1 GPRIOR | Global priority shadow for PRIOR [$DOlB] controls priority of player/missile/playfield. |
624 $270 8 PADDL0- PADDL7 | These locations store values returned when paddles are used. Values are between 0 and 228. |
632 $278 4 STICK0-STICK3 | These locations store values returned when a joystick is used. There are 9 possible values. These locations are shadows (duplicates) of ROM locations 53760 53767. |
636 $27C 8 PTRIG0-PTRIG7 | These locations store values of trigger on paddles. |
644 $284 4 STRIG0 | Joystick trigger 0 - 3. |
648 $288 1 CSTAT | Cassette status register. |
649 $289 1 WMODE | Used by cassette handler as read/write mode flag. Zero = read; $80 = write. |
650 $28A 1 BLIM | Cassette record data size count of number of data bytes being read. Range 1-128 depends on record control byte. |
651 $28B 4 SPARE | NO OPERATING SYSTEM FUNCTION. Use of these bytes in your program may conflict with later OS upgrades. |
656 $290 1 TXTROW | Text window row cursor range 0-3. Specifies where next read/write will occur. |
657 $291 2 TXTCOL | Text window column cursor range 0-39 used in split screen. These two variables give cursor position. |
659 $293 1 TINDEX | Split screen text window graphics mode. Index always = 0. When SWPFLG [$7B]=0. This is split screen equivalent of DINDEX. |
660 $294 2 TXTMSC | Split screen text window version SAVMSC [$58]. |
662 $296 6 TXTOLD | Old row and old column for text and then some split screen cursor data. |
668 $29C 1 TMPXI | Temporary storage. |
669 $29D 1 HOLD3 | Used by the display handler to hold scroll loop counter. |
670 $29E 1 SUBTMP | Temporary storage. Unknown function. |
671 $29F 1 HOLD2 | Temporary storage. Unknown function. |
672 $2A0 1 DMASK | Pixel location mask. |
673 $2A1 1 TMPLBT | Temporary storage for bit map. |
674 S2A2 1 ESCFLG | Used by screen editor. Flag set to $80 when ESC[$1B] character detected. Reset to 0 following output of next character. Causes character following ESC to be displayed, only exception is EOL [$9B]. |
675 $2A3 15 TABMAP | Indicates where tab stops are set. There are 120 possible tab stops in one logical line. |
690 $2B2 4 LOGMAP | Logical line bitmap. When a bit is set then a logical line starts at the corresponding physical row number. All bits set to 1 when text screen is opened or cleared. |
694 $2B6 1 INVFLG | Inverse video flag toggled by ATARI logo key sets bit 7 = 1 |
695 $2B7 1 FILFLG | Indicates to display handler whether current operation is Fill (not 0) or Draw (0) |
696 $2B8 1 TMPROW | Temporary storage used by ROWCRS [$54]. |
697 $2B9 2 TMPCOL | Temporary storage used by COLCRS [$55]. |
699 $2BB 1 SCRFLG | Scroll flag set to number of physical lines minus 1 that were deleted from top of screen. Since logical lines range from 1 - 3 physical lines then this variable ranges from 0 - 2. |
700 $2BC 1 HOLD4 | Used to save and restore value in ATACHR[$2FB] during kill process when ATACHR is temporarily set to value in FILDAT[$2FD]. |
701 $2BD 1 HOLDS | Similiar function to HOLD4. |
702 $2BE 1 SHFLOK | Shift/control lock flag initialized to $40 at powerup $00=normal mode lower case alpha $61-$7A $40=caps lock upper case $41-$5A $80=control lock $01-$1A |
703 $2BF 1 BOTSCR | Bottom of screen. If = 4, then mixed graphics mode. If = 24 then normal text mode. |
704 $2C0 4 PCOLR0 - | |
PCOLR3 | Player color registers and shadows |
PCOLR0 | = COLPM0[$D012] |
PCOLR1 | = COLPM1[$D013] |
PCOLR2 | = COLPM2[$D014] |
PCOLR3 | = COLPM3[$D015] |
708 $2C4 5 COLOR0 - | |
COLOR4 | Playheld color registers and shadows. |
COLOR0 | = COLPF0[$D106] |
COLOR1 | = COLPF1[$D017] |
COLOR2 | = COLPF2[$D018] |
COLOR3 | = COLPF3[$D019] |
COLOR4 | = COLBK[$DOlA] |
713 S2C9 23 SPARE | ** |
736 $2E0 2 GLBABS | Contains entry address of code for auto-boot/run. |
738 $2E1 2 SPARE | ** |
740 $2E4 1 RAMSIZ | Size in pages (page = 256 bytes) of available RAM permanently retains RAM top address contained in TRAMSZ[$6]. With BASIC and 48K installed this equals $160 =40960 bytes. |
741 $2E5 2 MEMTOP | Top of available user memory RAMSIZ less display list and display memory (first nonuseable program address). This value established by powerup logic and reset. Re-established when screen display is opened. |
743 $2E7 2 MEMLO | Bottom of available user memory established at powerup and reset, not altered after that. |
745 $2E9 1 SPARE | ** |
746 $2EA 4 DVSTAT | Device status buffer Get status command puts information in these bytes. |
750 $2EE 2 CBAUDL | Cassette baud rate low byte. |
752 $2F0 1 CRSINH | Cursor inhibit flag. When equal to 0 then cursor turned on. If not equal 0 then no visible cursor. |
753 $2F1 1 KEYDEL | Key delay set to 3 whenever key code accepted. Decremented every 1/60 sec by stage 2 VBLANK process until it reaches 0. |
754 $2F2 1 CH1 | Prior key code read and accepted. Current key pressed compared with contents of CH1 if same then debounce time checked if OK then accepted. If current key not the same as CH1 then accepted. When code is accepted then stored in CH[$2FC]. |
755 $2F3 1 CHACT | Shadow for CHACTL[$D401] character control register. |
bit 2 = 1 | Causes current character line to invert, sampled at every char. Iine. |
bit 1 = 2 | In 40 char. mode if bit 7 of current char. code = 1 then char. is blue on white. |
bit 0 = 1 | In 40 char. mode if bit I of current char. code = l then char. will be blank. Blinking char. produced by setting bit 7 of char. and periodically changing bit 0 here. |
756 $2F4 1 CHBAS | Vector to page address of character set initialized to $E0 (upper case and punctuation). The character set in ROM is located at $E000-$E3FF, shadow for CHBASE[$D409]. |
757 $2F5 5 SPARE | ** |
762 $2FA 1 CHAR | Contains internal code corresponding to what is in ATACHR[$2FB]. This will be converted to ATASCII code. |
763 $2FB 1 ATACHR | ATASCII value for most recent character read or written or value of the graphics point. This value also determines color of line in draw and fill commands. |
764 $2FC 1 CH | Holds keyboard code for a character (not ATASCII). Keyboard handler gets all data from here when it gets a character it writes $FF here to indicate code read. This location loaded when a key is pressed causing an IRQ interrupt which vectors at $208. This interrupt service routine loads the code into $2FC for processing at VBLANK stage 2. |
765 $2FD 1 FILDAT | Color to be used by XIO E:ILL Command. |
766 $2FE 1 DSPFLG | Display flag will allow control codes other than EOL [$98B] to be displayed if flag not equal to 0. If flag = 0 then control codes processed normally. |
767$2FF 1 SSFLAG | Start/stop flag toggled by control-1 keys cleared by break key, reset key, or powerup |
Page Three | |
---|---|
DCB DEVICE CONTROL BLOCK | |
Used for handler/SIO communication and between user and disk handler. | |
768 $300 1 DDEVIC | Pheripheral unit bus I.D. number. |
769 $301 1 DUNIT | Unit number. |
770 $302 1 DCOMND | Bus command. |
771 $303 1 DSTATS | Command type status return. |
772 $304 2 DBUFLO | Data buffer pointer. Set by handler to indicate source or destination data buffer. |
774 $306 1 DTIMLO | Device timeout in 64/80 second units. Set by handler. |
775 $307 1 DUNUSE | Unused in DCB. |
776 $308 2 DBYTLO | Number of bytes to be transferred into or out of data buffer. Not required if no data transfer. |
778 $30A 1 DAUX1 | Command auxiliary byte 1. Device specific information set by handler. |
779 $30B 1 DAUX2 | Command auxiliary byte 2. |
780 $30C 2 TIMER1 | Initial timer value. |
782 $30E 1 ADDCOR | Used for interpolation adjustment of baud rate. |
783 $30F 1 CASFLG | Cassette mode when set. |
784 $310 2 TIMER2 | Final timer value used with TIMER1 to compute interval for baud rate. |
786 $312 2 TEMPT | Temporary storage. |
788 $314 1 TEMP2 | ** |
789 $315 1 TEMP3 | ** |
790 $316 1 SAVIO | Save serial data port. |
791 $317 1 TIMFLG | Time out flag for baud rate correction. |
792 $318 1 STACKP | SIO stack pointer save cell. |
793 $319 1 TSTAT | Temporary status holder. |
794 $31A 38 HTABS | Start of handler address table. |
IOCB START OF I/O CONTROL BLOCKS | |
Used to communicate information between user program and CIO. | |
Space reserved for 8 IOCBs. | |
832 $340 1 ICHID | Handler index number ($FF = IOCB unused). |
---|---|
833 $341 1 ICDNO | Device number (drive number). |
834 $342 1 ICCOM | Command code. |
835 $343 1 ICSTA | Status of last IOCB action. |
836 $344 2 ICBAL | Buffer address. |
838 $346 2 ICPTL | Put byte routine address minus 1. |
840 $348 2 ICBLL | Buffer length. |
842 $34A 1 ICAX1 | Auxiliary information first byte. |
843 $34B 1 ICAX2 | Auxiliary information second byte. |
844 $34C 3 ICSPR | *** Spare bytes *** |
860 $350 16 IOCB # 1 | |
876 $360 16 IOCB # 2 | |
892 $370 16 IOCB # 3 | |
908 $380 16 IOCB # 4 | |
924 $390 16 IOCB # 5 | |
940 $3A0 16 IOCB # 6 | |
956 $3B0 16 IOCB # 7 | |
972 $3C0 40 PRNBUF | Printer buffer | .
1012 $3E8 21 SPARE | *** Spare bytes *** |
James Capparell, a native of Rochester, New York, and graduate of the University of Rochester, is the founder and publisher of ANTIC--The ATARI Resource. His interest in ATARI computers began while working as a programmer at NASA's Ames Research Center in Mountain View, Califomia. He also did programming for Ford Aerospace in Palo Alto. He originally obtained an ATARI to augment his NASA projects, but soon became involved with it as a hobbyist and as founder of ABACUS, the Atari Bay Area Computer Users' Society.