Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

CP/M disk info utility

449 views
Skip to first unread message

Jim Haug

unread,
Dec 16, 2022, 1:29:20 AM12/16/22
to
Does anyone know of a CP/M disk utility that can provide information on a floppy disk? My format utility says it's formatting my disks to ds/dd, so I should get something like 350-400k per floppy (35 or 40 tracks, 10 sectors per track, 512b per sector, double sided = 400k or 350k. The stat command reports an empty floppy to have 162k, whether I format with 35 or 40 tracks!

The floppy controller is a Morrow Designs DJDMA, the drives are Panasonic JU-455-7 which can do ds/dd. My older floppies (pre 1990) seem to be properly formatted. The current ones are formatting this way.

In any case, I was wondering if there is a utility that might be able to report on a disk layout. I've just now started hunting through archives, but I'll give this a shot too

Fritz

unread,
Dec 16, 2022, 3:45:32 AM12/16/22
to
Am 16.12.2022 um 07:29 schrieb Jim Haug:
> Does anyone know of a CP/M disk utility that can provide information on a floppy disk? My format utility says it's formatting my disks to ds/dd, so I should get something like 350-400k per floppy (35 or 40 tracks, 10 sectors per track, 512b per sector, double sided = 400k or 350k. The stat command reports an empty floppy to have 162k, whether I format with 35 or 40 tracks!
>

You can realy use stat but there are other tools.

There are SKEW, DPB, DSKPRAM, PROBE, DSKSTAT available.

Some of them are in the folder of https://oldcomputers-ddns.org/public/pub/rechner/elzet80/bcs-konverter/images/files/disk-10/index.html
and most are on the walnut creek cp/m cdrom



--
-- Fritz

Fritz

unread,
Dec 16, 2022, 3:55:26 AM12/16/22
to
The tools all use the DPB/DPH parameter and internals of the CP/M system but don't show what is on the floppydisk.
You can use Anadisk on a PC to test the floppydisk and even can try IMD for creating images of it.

I believe there must be a softswitch for your formater.



--
-- Fritz

Fritz

unread,
Dec 16, 2022, 4:17:00 AM12/16/22
to
Am 16.12.2022 um 07:29 schrieb Jim Haug:
> Morrow Designs DJDMA


interesting ... it's a s100 bus card - I had 20years ago some of the IMS5000 IMS8000 parts.

http://www.s100computers.com/Hardware%20Folder/Morrow/DJDMA%20FDC/DJDMA%20FDC.htm

As I'm interested please tell us a little bit more about your system - maybe on VCFED you will got more answers.




--
-- Fritz

Douglas Miller

unread,
Dec 16, 2022, 6:49:30 AM12/16/22
to
This is a classic CP/M issue, since DRI does not define how floppies are formatted - just how the BIOS tells the BDOS to use the tracks/sectors on the floppy. Each CP/M vendor (BIOS) had to design their own format utility and how the floppy format(s) relate to what data is given to the BDOS. Some systems had auto-detect built into their BIOS, others provided a way to set flags in the BIOS to tell it what to expect from the floppy. Regardless of whether a diskette is formatted DS, it will still appear to be SS unless something tells the BIOS to use the second side. I know nothing about the Morrow BIOS, but you may need to find some sort of "mode" utility to change the BIOS characteristics so that both sides are used. In some extreme cases, you may have to rebuild the BIOS, SYSGEN, and reboot in order to use different format. I would hope Morrow had a better plan than that, since the format utility allows you to make those choices.

Douglas Miller

unread,
Dec 16, 2022, 6:53:29 AM12/16/22
to
Note that BIOSes that do auto-detect usually only perform that check if the drive was "logged off" - i.e. on first access to the drive after warm boot (log in). Depending on how your format utility returns to the CP/M prompt, it may be necessary to do a Ctrl-C before checking the new floppy, in order to trigger the auto-detect (provided Morrow BIOS is doing auto-detect).

Steve Mastriannni

unread,
Dec 16, 2022, 1:52:11 PM12/16/22
to
Also duf05 and DUU. I use both.

--Steve

Jim Haug

unread,
Dec 18, 2022, 1:04:24 AM12/18/22
to
Good point. I built a North Star Horizon in 1978. In 1981 I swapped out the North Star boards for a Compupro CPU-Z Z80, Compupro RAM 17 64k static ram, and a Morrow DJDMA floppy controller. I also got rid of the original Horizon floppy drives and replaced them with ds/dd drives, Teac IIRC. Those are long gone--I loaned them to someone and never got them back. A couple of years ago I began reviving the system and picked up several Panasonic JU 455-5/7 drives. These are 40 track ds/dd drives. The system uses the old North Star 10-sector hard sector floppies.

Earlier this year I'm sure I remember formatting a couple of floppies to ds/dd. Now I only seem to get ss/dd. That's why I was hunting for a utility to check that.

Here's the weird thing. I have spare boards for the ram, processor, and fdc. I get the same results no matter which I use. I've also swapped cables and gotten the same results

Very mysterious

retrogear

unread,
Dec 18, 2022, 5:35:57 AM12/18/22
to
Do you have a terminator on the drive ? I'm reading that side select on that drive might need a pullup resistor

Larry G

Jim Haug

unread,
Dec 19, 2022, 1:18:30 AM12/19/22
to
On Sunday, December 18, 2022 at 3:35:57 AM UTC-7, retrogear wrote:
> Do you have a terminator on the drive ? I'm reading that side select on that drive might need a pullup resistor
>
> Larry G
Both drives had pullup resistors installed. I recall that only the furthest drive in the chain (B: in this case) should have one, so I removed the one from Drive A:. Made no difference.

Here is a log of querying the drives using probe.com. Drive A: in this case contains a floppy formatted recently. Drive B: contains a floppy formatted 40 years ago


---------- 2022-12-18 22:57:44 -0700: Logging Started ----------

^C
Morrow/North Star BIOS 1.5 JKH 1-Apr-85

A>probe

PROBE Version 1.01 2 Sep 1984

PROBE will tell you what version of CP/M or MP/M you are
running, and display the I/O byte if appropriate. It then
displays the addresses of the CCP, BDOS, and BIOS. The BIOS
jump table will next be displayed including the extended BIOS
calls for CP/M+, and XIOS calls if running MP/M. It then
displays the disk parameter blocks (DPB's), disk parameter
headers (DPH's), group size, total disk size, number of
directory entries, space required for directory entries, total
usable space on the disk, and the disk space allocation vectors
for any selected drive (A: through P:).

PROBE was written in 'c' to help decode the disk formats of
a number of different machines to aid in transportability. It
was inspired by BDLOC, TELL, ALLOC, and a number of other public
domain CP/M utilities.

Paul Sittler - My Word!! RCP/M (409) 845-0510 (late nights)
Veterinary Public Health RCP/M (409) 845-0509 (24 hours)
Dept of Veterinary Public Health, Texas A&M University
College Station, Texas 77840-4468

This is CP/M 2.2.

I/O Byte value is currently 255 decimal,
FF hexadecimal or [1111 1111] binary

LST: is currently 03 hex or [11 ] binary, or UL1:
PUN: is currently 03 hex or [ 11 ] binary, or UP2:
RDR: is currently 03 hex or [ 11 ] binary, or UR2:
CON: is currently 03 hex or [ 11] binary, or UC1:
-----------
Making the IOBYTE FF hex or [1111 1111] binary

where, for the following devices:

Device LST: PUN: RDR: CON:
Value 11 11 11 11
00 assigns TTY: TTY: TTY: TTY:
01 assigns CRT: PTP: PTR: CRT:
10 assigns LPT: UP1: UR1: BAT:
11 assigns UL1: UP2: UR2: UC1:

[1111 1111] assigns UL1: UP2: UR2: UC1:

This portion will tell you where your CCP starts, what
your BDOS entry address is, and where your CBIOS jump table
begins. The CBIOS jump table is also displayed.

Your CCP beginning address is: D500H.
Your BDOS beginning address is: DD00H.
Your BDOS entry address is: DD06H.
Your CBIOS jump table begins at: EB00H.
Cold start routine address is: EB03H.
Warm start routine address is: ECA9H.
Console Status routine address is: EB96H.
Console Input routine (waits for char.): EB48H.
Console Output routine address is: EB4FH.
List device output routine address is: EB70H.
Punch device output routine address is: EBD0H.
Reader device input routine address is: EBD3H.
Home disk routine address is: ECF0H.
Select disk routine address is: ED02H.
The set track disk routine address is: ECF3H.
The set sector disk routine address is: ECE4H.
The set DMA disk routine address is: ECEAH.
The read disk routine address is: EDFCH.
The write disk routine address is: EDF3H.
List device status routine address is: EBB7H.
Sector translate disk routine address is: ECF9H.

Do you wish to PROBE a drive's parameters (Y/N) ? y
Which drive do you wish to PROBE (A - P) ? a

For drive A:, the disk parameter block address is 0F511 hex

The disk parameter block as it appears in memory (in hex):
F511 28 00 04 0F 01 51 00 3F 00 80 00 10 00 02 00

Parameter (SYM) Hex Decimal [ Binary ]
Sectors per Track (SPT) = 0028 40
Block Shift Factor (BSH) = 04 4
Allocation Block Mask (BLM) = 0F 15
Extent Mask (EXM) = 01 1
Disk Size Maximum (DSM) = 0051 81
Directory Maximum -1 (DRM) = 003F 63
Allocation Mask 0 (AL0) = 80 128 [1000 0000]
Allocation Mask 1 (AL1) = 00 0 [0000 0000]
Directory Check Size (CKS) = 0010 16
System Tracks Offset (OFF) = 0002 2

The whole disk parameter block looks like:
SPT: BSH: BLM: EXM: DSM: DRM: AL0: AL1: CKS: OFF:
0028 04 0F 01 0051 003F 80 00 0010 0002

For drive A:, the disk parameter header address is 0F561 hex

The disk parameter header as it appears in memory (in hex):
F561 00 00 0E 00 0B 00 B8 01 B2 FA 11 F5 BD FB CD FB

Address Vector Description (SYM) Hex
Log to physical sector trans (XLT) = 0000
Directory buffer scratchpad (DIRBUF) = FAB2
DPB address in DPH (DPB) = F511
Check changed disk scratchpad (CSV) = FBBD
Disk space allocation vector (ALV) = FBCD

The data allocation block or group size is 2 Kbytes
The total disk size is . . . . . . . . . . 164 Kbytes
The # of directory entries blocked for is 64 Entries
which requires . . . . . . . . . . . . . . 2 Kbytes
Leaving a useful disk capacity of. . . . . 162 Kbytes


2K Disk Allocation Block Number
(Hex) 0123 4567 89AB CDEF 0123 4567 89AB CDEF
----- ---- ---- ---- ---- ---- ---- ---- ----
0000: 1111 1111 1111 1111 1111 1111 1111 1111
0020: 1111 1111 1111 1111 1100 0000 0000 0000
0040: 0000 0000 0000 0000

Do you wish to PROBE a drive's parameters (Y/N) ? y
Which drive do you wish to PROBE (A - P) ? b

For drive B:, the disk parameter block address is 0F551 hex

The disk parameter block as it appears in memory (in hex):
F551 28 00 04 0F 01 C2 00 3F 00 80 00 10 00 02 00

Parameter (SYM) Hex Decimal [ Binary ]
Sectors per Track (SPT) = 0028 40
Block Shift Factor (BSH) = 04 4
Allocation Block Mask (BLM) = 0F 15
Extent Mask (EXM) = 01 1
Disk Size Maximum (DSM) = 00C2 194
Directory Maximum -1 (DRM) = 003F 63
Allocation Mask 0 (AL0) = 80 128 [1000 0000]
Allocation Mask 1 (AL1) = 00 0 [0000 0000]
Directory Check Size (CKS) = 0010 16
System Tracks Offset (OFF) = 0002 2

The whole disk parameter block looks like:
SPT: BSH: BLM: EXM: DSM: DRM: AL0: AL1: CKS: OFF:
0028 04 0F 01 00C2 003F 80 00 0010 0002

For drive B:, the disk parameter header address is 0F571 hex

The disk parameter header as it appears in memory (in hex):
F571 00 00 10 00 00 00 00 00 B2 FA 51 F5 E3 FB F3 FB

Address Vector Description (SYM) Hex
Log to physical sector trans (XLT) = 0000
Directory buffer scratchpad (DIRBUF) = FAB2
DPB address in DPH (DPB) = F551
Check changed disk scratchpad (CSV) = FBE3
Disk space allocation vector (ALV) = FBF3

The data allocation block or group size is 2 Kbytes
The total disk size is . . . . . . . . . . 390 Kbytes
The # of directory entries blocked for is 64 Entries
which requires . . . . . . . . . . . . . . 2 Kbytes
Leaving a useful disk capacity of. . . . . 388 Kbytes


2K Disk Allocation Block Number
(Hex) 0123 4567 89AB CDEF 0123 4567 89AB CDEF
----- ---- ---- ---- ---- ---- ---- ---- ----
0000: 1111 1111 1111 1111 1111 1111 1111 1111
0020: 1111 1111 1111 1111 1110 0001 0000 0000
0040: 0000 0000 0000 0000 0000 0000 0000 0000
0060: 0000 0000 0000 0000 0000 0000 0000 0000
0080: 0000 0000 0000 0000 0000 0000 0000 0000
00A0: 0000 0000 0000 0000 0000 0000 0000 0000

Do you wish to PROBE a drive's parameters (Y/N) ? n
A>

---------- 2022-12-18 22:58:52 -0700: Logging Stopped ----------

Douglas Miller

unread,
Dec 19, 2022, 4:23:54 AM12/19/22
to
It sounds like the PROBE utility is only telling you what CP/M thinks the floppy drive is, which is really the same as using STAT.

I'm thinking two possibilities here, not knowing anything about Morrow's version(s) of CP/M.

A) If Morrow CP/M writes a sector to the floppy that contains format data for CP/M, perhaps the FORMAT program you're using is not doing that.

B) If this recently formatted disk is not what you booted off, you need to "reset" the drive so that Morrow CP/M will try to auto-detect. That will be difficult if you did not SYSGEN the new disk.

It may also be the case that it's something like you formatted the floppy DS but sysgened with a copy of CP/M configured for SS A:. This all depends on how Morrow CP/M works w.r.t. detecting or configuring drive formats.

Fred J. Scipione

unread,
Dec 22, 2022, 1:31:56 AM12/22/22
to
In article <1a9f2c93-d833-485f...@googlegroups.com>,
durga...@gmail.com says...
>
> It sounds like the PROBE utility is only telling you what CP/M thinks
> the floppy drive is, which is really the same as using STAT.

Still, the Probe info. is somewhat revealing. Both drives A: and B:
report as 40 (logical) sectors per track. That corresponds with 10
physical sectors of 512 bytes per track. The drive A: numbers work
out to 200K on 40 tracks and drive B: to 400K on 80 (logical) tracks.

More Probe results from some additional testing could again be
useful. Does swapping diskettes in drive B: cause the Probe results
to follow the diskette? If not, does a warm boot cause it to track?
With-warm-boot means the CBIOS has some functional auto-detect.
Without-warm-boot means the CBIOS clues off of door-close/ready signal.

Using DDT, or creating a small program (via DDT, ASM, or Small-C) to
make CBIOS calls to read (logical) sectors could demonstrate actual
proper hardware operation (head select, logical track to physical
track+head mapping, seeking, etc.) Homing, then reading logical sector
37 on logical tracks 0, 1, 19, and 39 could produce an audible pattern
of stepping to physical tracks. That could reveal if one of the common
track+head mappings is implemented in the CBIOS:
1. Even tracks on head 0, odd tracks on head 1.
2. Up side 0, then up side 1.
3. Up side 0, then down side 1.

Using the strings command (from Walnut Creek CP/M CDROM:
simtel/hz100/m-z/strings.zip?) on your format command's binary might
yeild some clues for the proper command option to get a DS format
result.

It may be that you actually need some separate DS format command. If
You cannot get the current format command to do DS, and cannot find a
DS format command, you may have to resort to dis-assembly of the current
command (and part of the CBIOS, to learn how to do head select) in
order to make your own DS format command (by modifying the dis-assembled
current command?). Be sure that you implement any demonstrated CBIOS
track+head mapping, sector header numbering skew, etc.

Dennis Boone

unread,
Dec 25, 2022, 6:18:03 PM12/25/22
to
> Earlier this year I'm sure I remember formatting a couple of floppies to
> ds/dd. Now I only seem to get ss/dd. That's why I was hunting for a
> utility to check that.

> Here's the weird thing. I have spare boards for the ram, processor, and
> fdc. I get the same results no matter which I use. I've also swapped
> cables and gotten the same results

I've just read back through the thread quickly: it's possible I missed
something (I swear I can read...), but -

Given that side select is a single signal, and that I don't see you've
swapped out the drives, it seems possible that there might be a hardware
issue on the drive.

De
0 new messages