!M-11MAY87 BD HLP/^BD INF!BD04 COM$,BD04 INFP ? BD BAD DISK PROGRAM =================== 11 May 1987 Irv Hoff NOTE: BD04 works with either CP/M v.2.2 or v3.0 GENERAL: ------- 'BD' stands for "bad disk". It reads the records on a disk (floppy or hard) and finds those that are unacceptable. It then makes a file named [LOCKED].OUT containing those records. This prevents them being used in any new files, thus allowing normal use of the disk. It also shows the names of any files that might be defective. It works with CP/M v2.2 or v3.0 (often called CP/M+). It is 5-1/2k in length. Small floppies usually have 1k blocks, larger floppies 2k blocks. Most hard disks use 4k blocks although a few have 8k blocks. 'BD' counts the blocks in increments of 5. A disk with 360k would thus show 180 blocks. A hard disk partitioned for 8 Mb per drive and using 4k blocks will show 2048 blocks (etc.) If a block has one or more bad records, this informaion overwrites the progress report. It then resumes the progress report on the following line. This gives an attractive display. TO USE: ------ Any of the following three will work. The first permits removing the disk from the current drive and replacing with the disk to be checked. Useful for only one drive or if you want to check a disk in any drive. (For floppies, it is often beneficial to check the same disk in every drive you have, they occasionally act differently in different drives.) A>BD activates pgm, will ask what drive A>BD B activates pgm, checks drive B: A>BD B: activates pgm, checks drive B: NOTE: The program can be aborted at any time, but but in a somewhat unusual manner. Just type type CTL-S to stop the display and then CTL-C. EXAMPLE 1: --------- If the disk already has a [LOCKED].OUT file from a previous check, the results might look like this: BD v04 - bad disk blocks/files check drive: A (automatically logs in that drive) checking.... prior check: 127 prior check: 148 prior check: 149 prior check: 160 this check: 162 prior check: 204 this check: 225 494 (total data blocks checked) bad blocks: 7 bad files: A:CRT ASM A:LIST DOC A> As it checks the file, if the current block has previously been reported as bad, that is shown as "prior check", and if not previously reported, it shows as "this check". Thus you can see if the disk has new problems since the prior check. You can manually erase the [LOCKED].OUT file if you wish and rerun the program to see what it will report "this time". (If results vary more than slightly, you may have a bum drive that is giving erratic results, or that initially did a poor job formatting the disk.) When showing 'bad files' it may show the same file name more than one time, indicating that particular file has multiple bad areas and will be difficult to rebuild into a normal file. NOTE: 2k blocks have 16 records. Thus a bad block could have from 1-16 bad records. 4k blocks have 32 records. Thus a bad block could have from 1-32 bad records. EXAMPLE 2: --------- This is what you are hoping to see, for a normal disk: BD v04 - bad disk block/files check drive: B checking.... 494 bad blocks: 0 bad files : 0 B> OPTIONS: ------- 1) 0103h sets the user area for [LOCKED].OUT file. 00 = user area zero 0F = user area 15 2) 0105h turns progress reports on/off. You may want a version with them turned off, so you can use the printer to display the results. 00 = no progress reports FF = progress reports shown (anything but 00) (then save 22 pages if using DDT or SID, etc.) - Irv Hoff W6FFC BD is a 'Bad Disk' program that replaces FBAD (FINDBAD). It writes a [LOCKED].OUT file with blocks containing any bad sectors. The disk can then still be used in a normal manner. Unlike FBAD it also shows the names of any files that were affected. This universal version is for both CP/M v.2.2 and v3.0 (often called CP/M+). 90 records, 12k. KBD v04 - 11 May 87 - put user number in 0103h, FF in 0105h to show progress, 0 to suppress. Program finds and locks out any bad blocks, then shows any files that are affected. Irv Hoff $:::2 2:<2د2> *2> _  |{0~og}o|g~#fos#r1Ê . *"|!,|}!‰‰,ɯ|u!|}!-{ ´ ʹ |}rz!--{!-z{rz{!||g}o){ozg|/g}/o!#DMl|LLDM͔((|(N#F#xk~#~#TT!xGyOҁҁ\ ,k ,z :+B}!![LOCKED]OUT?????????????!9>"ͣ*.oʼ*.!%͕o*#"+.ͣã*#"+.͋!"*.!0ͽ*.!9;oC ! *-*#"+."! }2! "!"*#"+.û!9>!9>ͣ!9>.|ʰ!9>#C+.ͣ*+"Â! Rddscsͣ!9>0ͣ*+"!ͽ:/ͣ*+"#!9>!&*! woL*+"#!9!9>(C!"!9>*m!9>!ͽoʕ*|ʆ!-ͣ!9>)*!wʻ!9>!!4*! w!9>! 2!9>!!4*! w!9>! 2$!9>*+4 FCB scrogged$ Disk changed$ Unknown error$!a"D!a"B!a"V!͕!"0*0>%"0͞*4"4!#"@*@*0>C! *:\Q@:]A$Q$262!͕/!A"6!h͕*6! wG*6}2<2c!Ak*6!A͹ot*6!A͕ʁ! }2U:U/! w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>*ʑ:/+}2Ü:/#}2!j;*!9!}!F"!9>#C+!9.! !9.#}+*#".!9>#C+.͕!"3!*$!"$*$! oL*$#"$+0!9>#C+!9>#C.}A"$!9>!9>ʔ!9>Û!9>! !!͹ʾ!*0>#C+"*#"*0>+C#͕!!"4*4>"4*4!4!͕!!9>g!m͕Ä!͕Ä!͕Ä!͕Ä!͕Ä!͕ÄR*4!9>>!4 BD v04 - bad disk blocks/files check drive: checking.... 0 checking.... check drive: prior check: %d this check: %d bad blocks on : %d bad files: %c:bad files on : 0  will not work with MP/M will not work if BIOS is in ROM Sync error ++ error closing file ++ ++ directory is full ++  Note: BD v04 works equally well on either CP/M v2.2 or v3.0. Numerous programs exist to check disks for bad records. Several of them are commercial programs such as BADLIM, DSKMGR and RECLAIM. A few are free such as BD, FINDBAD (often called FBAD) and Verify. All these programs construct a file which includes the bad records. BD is the only free program that also shows the name of any file that has one or more of the bad records. BD v04 is current. I tried on earlier releases to make it work on CP/M+ as well as CP/M v2.2 but with unsatisfactory results. A friend from Australia (Jonathan Saxton) became interested in the program. He is the sharpest person I know with regard to CP/M+. He was able to finish up the program for satisfactory use with CP/M+. BD04 now works automatic- ally with CP/M v2.2 or v3.0 either one. Read the BD.HLP file to see what features the programs offers and how to interpret the information it supplies. This program is a "must have" utility that any CP/M user should keep on his master disk. It is not only more versatile than FINDBAD (or FBAD), but somewhat faster, as well. HINT: Rename to BD.COM when placing on your master disk. - Irv Hoff 11 May 87