6

I've been toying around with various drive geometries using the classic HDToolbox from 2.x/3.1 on my Amiga. What I've discovered is the total size calculated is always 1 cylinder short of my own calculations.

for example, consider the following as reported by HDToolbox

          Cylinders: 3855
              Heads: 1
   Blocks per Track: 1088 
Blocks per Cylinder: 1088 
               Size: 2096576K (2047Meg)

Note: Blocks per Track is really just Sectors, and Blocks per Cylinder is really just Sectors times Heads.

Assuming TotalNumberOfBlocks = (Cylinders x Heads x Sectors) and TotalSize = (TotalNumberOfBlocks x 512 bytes per block) then

TotalNumberOfBlocks = 3855 x 1 x 1088 = 4,194,240
TotalSize = 4,194,240 x 512 = 2,147,450,880 bytes (or 2,097,120Kb)

If I calculate the size as shown above I get 2,097,120Kb but HDToolbox reports 2,096,576Kb, which is a discrepancy of 544Kb (or 557,056 bytes).

That looks weird, until you realize it is exactly 1 cylinder.

 1088 Blocks per Cylinder * 512 bytes = 557,056 bytes

I've tried this multiple times with multiple geometries, and its always 1 cylinder short of a full deck disk.

My working hypothesis is that HDToolbox subtracts 1 cylinder from the drive size to account for parking the read/write heads. Can anyone confirm this theory?

3
  • 1
    The first partition will usually start on the 2nd cylinder of the physical disk. So, I think HDToolbox is showing you the total size of the logical disk (for partitions), and not the physical disk, which puts the RDB on the first cylinder.
    – Brian H
    Jul 18 at 1:24
  • @Brian, I considered that too, but I am assuming the cylinder index is zero based, so if the first partition starts on cylinder 2, then cylinders 0 and 1 are reserved for the RDB. HDToolbox is definitely only subtracting a single cylinder from the totals, so I assumed they were counting the 2 reserved cylinders in the total and subtracting one as 'unavailable' because that's where they park the heads.
    – Geo...
    Jul 18 at 12:15
  • 1
    @Geo... There's a difference between a count and a number. Them being 0-indexed wouldn't change the number total. There are still just 3855 cylinders, and you get the discrepancy of exactly 1 of them. Jul 18 at 12:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.