Reading the disk with the CATalog? ALL query
The following example program reads the catalog of the disk currently in the
logic analyzer disk drive. The CATALOG? ALL query returns the entire
70-character field. Because DOS directory entries are 70 characters long,
you should use the CATALOG? ALL query with DOS disks.
10 ! ****** DISK CATALOG ******
20 ! using the CATALOG? que ry
30 !
40 DIM File$[100]
50 DIM Specifier$[2]
60 OUTPUT 707;":EO I ON"
70 OUTPUT 707;":SY STEM:HEADER OF F"
80 !
90 OUTPUT 707;":MM EMORY:CATALO G? ALL" ! send CATAL OG? ALL query
100 !
110 ENTER 707 USING "#,2A";Specifier$ ! read in #8
120 ENTER 707 USING "#,8D";Length ! read in block length
130 !
140 ! Read and print each file in the directory
150 !
160 FOR I=1 TO Length STEP 51
170 ENTER 707 USING "#,51A";File$
180 PRINT File$
190 NEXT I
200 ENTER 707 USING "A";Specifier$ ! read in final line feed
210 END
Programming Examples
Reading the disk with the CATalog? ALL query
36–25