Ad: Click Here

Mapping the Atari cover

APPENDIX SEVENTEEN

DOS 2.5 And The 1050 Drive

The latest version of DOS (Disk Operating System) for the XL and XE computers is 2.5. It offers several advantages over the earlier ver- sions (including the ill-received DOS 3.0), including dual-density formatting, new XIO formatting commands available from BASIC, a RAMDISK program for the 130XE, and greater compatibility with DOS 2.0. If you use DOS 3.0, I suggest you get a copy of 2.5 as soon as you can. DOS 2.5 formats a track with 26 sectors instead of the 18 DOS 2.0 han- dles; this means a disk with 1010 sectors free instead of 707 (leaving 931 free sectors with DOS and DUP.SYS files on a disk). The 1050 (not the 810) drive can automatically sense which density the disk in the drive is using. DOS 2.0 can read a 2.5 disk but the additional sectors are invisible to it.

New BASIC Commands for DOS 2.5

When you OPEN a disk from BASIC to get a directory read (see loca- tion 1792; $700 in the Addenda section), you normally use OPEN #1,6,0,"D:*.*." Now, if you use OPEN #1,7,0,"D:*.*," DOS will specify files which occupy disk sectors that can't be accessed by 2.0 with angle brackets, like . These files are invisible to DOS 2.0 when reading a directory; they can't be loaded, nor do they show up in the directory. Formatting the disk by the XIO command is enhanced. The usual method is XIO 254, #1,0,0,"D1:." This will format the disk, trying first for dual density, and if the drive doesn't support it, formatting in single (2.0) density. XIO 253, #1,0,0,"D1:" formats a disk with single density only (a new option--P--has been added to the DOS menu to format in single density as well). XIO 253, #1,34,0,"D1:" will format a disk in dual density only.

RAMdisk for the 130XE

DOS 2.5 includes a special program called RAMDISK.SYS. This loads up when the disk is booted and determines if your computer is a 130XE. If so, it runs a small program which creates a "disk drive" out of the 64K extended memory bank. The RAMdisk acts just like a real disk, except that it's faster. It is formatted into 499 sectors and a direc- tory and has the drive number D8:. DOS 2.5 supports drives 1-8, but is initialized to drives 1, 2, and 8, so if you have other drives, change location 1802 ($70A); that is, if you have three drives and the RAMdisk, POKE 1802, 135. All bits in location 1802 now represent pos- sible drives. When it runs, RAMDISK.SYS copies MEM.SAV and DUPSYS to the RAMdisk, then modifies a location so that you call up DUP.SYS from the RAMdisk rather than D1:. This brings up DOS almost immediately when you leave BASIC. However, if you want to delete DUP.SYS from the memory drive and call it up from drive 1 as usual, type POKE 5439, ASC("1"), this points DOS back to the original drive. You can also delete MEM.SAV from D8: if you don't need it.

DOS 2.5 Boot Sector and Memory Map

Locations 1792-1812 ($700-$714) are loaded directly into RAM from the boot sector (sector 1) on a disk. Refer back to the section in the 400/800 memory map tar more explanation. These are from an article by Neil Harris in the Atari Explorer; they are locations Atari promises to support in the future:

1792 700 BFLG

Boot flag; always equals 0.

1793 701 BRCNT

Number of sectors in the disk boot; three--the first three on the disk.

1794,1795 702,703 BLDADDR

Boot load address; where DOS is loaded into memory; always 1792 ($700).

1796,1797 704,705 BINTAD

DOS initialization address; always 5440 ($1540).

1798-1800 706-708 BCONT

JMP instruction to jump to the address where the boot program continues execution; 1812 ($714).

1801 709 SABYTE

Maximum number of concurrently open files--usually three.

1802 70A DRVBYT

Drive allocation byte; one bit per drive.

1803 70B SAFBFW

Unused.

1804,1805 70C,70D SASA

Buffer allocation address for drives and files.

1806 70E DFSFLG

Reads zero if there is no DOS.SYS on disk, nonzero if present.

1807,1808 70F,710 DFLINK

Points to first sector of the DOS.SYS file.

1809 711 BLDISP

Number of displacement bytes to sector link bytes (last three); always 125 ($7D).

1810,1811 712,713 DFLADDR

Address of the FMS (D:) handler table; 1995 ($7CB).

1812 714 XBCONT

Boot program begins here.

1900 76C BSIO

BASIC SIO routines.

1906 772 BSIOR

FMS disk handler routines.

1913 779 ....

Write verify flag; 80 ($50) turns it off, 87 ($57) turns it on.

1995 7CB DFMSDH

FMS handler table. Has data in it different from 2.0 handler.

2016 7E0 DINIT

DOS initialization routine.

4993 1381 FBC

Start of the FMS file control blocks; first of eight.

5121 1401 FILDIR

128-byte buffer for a disk directory sector.

5439 153F ....

POKE with 49 (ASC("1")) to reroute DOS to call DUP.SYS from D1: rather than D8: when using the RAMdisk--you can then delete DUP.SYS and MEM.SAV from the RAMdisk for extra space. See location 1923 ($783) in the Addenda.

5440 1540 MINIDUP

Start of permanently resident portion of DUP.SYS.

5540 154A SFLOAD

Entry to DUP.SYS's routine to load binary files.

5542 15A6 STLOAD

Used with SFLOAD.

5545 15A9 LOAD

Used with SFLOAD.

Return to Table of Contents | Previous Chapter | Next Chapter