home *** CD-ROM | disk | FTP | other *** search
- 30 rem for 4040/2031/1540/1541
- 40 print "[147]disk purge"
- 50 print:print"which drive (0/1) ? [146][157]";
- 60 get dr$:if dr$<>"0" and dr$<>"1" then 60
- 70 print dr$:d=val(dr$)
- 80 dr$= "i"+dr$:open 15,8,15,dr$
- 90 gosub 450
- 100 open 1,8,3,"#":gosub 460
- 110 print:print "press'y[146]'to del file":print
- 120 z$=chr$(0)
- 130 t=18:s=1
- 140 print#15,"u1:"3;d;t;s
- 150 print#15,"b-p:"3;2+32*r
- 160 get#1,a$:if a$="" then a$=z$
- 170 if asc(a$)<129 then 270
- 180 for k=5+32*r to 20+32*r
- 190 print#15,"b-p:"3;k
- 200 get#1,a$:if a$="" then print" [146]";:goto 220
- 210 print a$;
- 220 next
- 230 print ,,"purge ? [146][157]";
- 240 geta$:ifa$<>"y" and a$<>"n" then240
- 250 print a$
- 260 if a$="y" then gosub 360
- 270 r=r+1:if r<8 then 140
- 280 print#15,"b-p:"3;0
- 290 get#1,a$:ifa$="" thena$=z$
- 300 t=asc(a$):if t=0 then print:print "end of directory.":goto 400
- 310 print#15,"b-p:"3;1
- 320 get#1,a$:ifa$=""thena$=z$
- 330 s=asc(a$):print:print "*** next track: ";:nu=t:gosub520:print n$;
- 340 print tab(20);"next sector: ";:nu=s:gosub 520:print n$;" ***":print
- 350 r=0:goto140
- 360 print#15,"b-p:"3;5+32*r-3
- 370 print#1,chr$(0);
- 380 print#15,"u2:"3;d;t;s
- 390 gosub460:return
- 400 close 1
- 405 print "validate disk y or n"
- 406 get v$:if v$="y"then410
- 407 if v$=""then 406
- 408 close15:end
- 410 print:print "validating disk[146]"
- 420 print#15,("v"+dr$)
- 430 gosub460:close 15
- 440 end
- 450 rem check disk status
- 460 input#15,er,er$,tr,se
- 470 if er=0 then return
- 480 close 15:close 1
- 490 print:print "disk error! ";
- 500 print er;er$;tr;se
- 510 stop
- 520 rem format (NULL)s
- 530 n$=mid$(str$(nu),2)
- 540 if len(n$)<2 then n$="0"+n$
- 550 return
-