10REM Read the current directory's ca
talogue into memory using a modified ver
sion of the block used for OSFSC
20REM 0,WRADDR,NOF,0,0,0,0
30REM WRADDR=address at which catalog
ue is to be written (4 bytes)
40REM NOF=no. of files to read catalo
gue for ie.32 max for DFS (4 bytes)
50REM Set up block to CAT at block %
and use code% as block area
60DIM code% &40
70DIM block% 512
80P%=code%
90[
100EQUB0
110EQUD&FFFF0000+block%
120EQUW&0000:EQUW&0080
130EQUW&0000:EQUW&0000
140.docat
150LDA#8
160LDX#code% MOD256:LDY#code% DIV256
170JMP&FFD1
180]
190REM On exit the first byte in the b
lock is the Disk's cycle number,followed
by the number of file's catalogues that
were not read (if NOF was too small)
200REM At the address block% data is r
eturned as LON1,NAME1,LON2,NAME2 etc and
does not include the directory name
210OSCLI"MEM."+STR$÷(code%)
215REM Or replace the above line with
your memory dumper's command name,for ex
ample *MZAP for Disc Doctor
220CALL docat
230PRINT:PRINT"Cycle number:"÷?code%
240OSCLI"MEM."+STR$÷(block%)
245REM Or replace the above line with
your memory dumper's command name,for ex
ample *MZAP for Disc Doctor
250PRINT''"Proof:"'
260*.
270A=GET:RUN