IDENTIFY ESDI DRIVE

As previously mentioned on this site, the IDENTIFY DRIVE command in the ATA specification almost certainly first appeared in ESDI controllers supplied to Compaq by Western Digital.

Since I have now finally secured a working ESDI hard disk, I could do some probing. Unfortunately I don’t have access to a WD1005 ESDI controller that should be extremely close to what Compaq used circa 1986, but I have two of its successors, WD1007A and WD1007V. A spare WD1005 anyone?

My WD1007A (1987) clearly came out of a Compaq machine and it is a rather interesting piece of hardware. It is a hard disk controller only, with no floppy support. It also has no BIOS (though other models did, and the PCB clearly has room for it).

The newer WD1007V-SE2 (1989) might be a retail model; it includes a floppy controller and a BIOS, although the BIOS can be disabled since it wasn’t necessary in many PC/AT compatibles.

WD1007A and WD1007V ESDI controllers

Now, what’s very interesting about these WD ESDI controllers is that from a software perspective, they would be very difficult to distinguish from an IDE drive. They support the exact same registers and commands as a standard PC/AT controller, but additionally also implement the IDENTIFY DRIVE command. At least in the case of the WD1007V, the controller also supports READ/WRITE MULTIPLE commands, READ/WRITE BUFFER commands, and probably some form of cache control. In other words, the WD1007V even acts like a not so basic IDE drive.

Now back to IDENTIFY DRIVE. That would have been the big difference between a controller for ST506 style MFM or RLL drives and an AT-compatible ESDI controller. ST506 (or ST412, if you’re Seagate) drives simply have no mechanism to report their characteristics to the controller. But ESDI drives do. Anyway, let’s look at the details…

To obtain IDENTIFY DRIVE data, I hooked up the WD1007 controllers to a Seagate ST4182E drive. This model started its life as CDC Wren III, available with ESDI or SCSI interfaces. The Wren III started shipping in 1986 and Seagate was still making the drives in 1991, when my specimen was produced.

Seagate ST4182E aka Wren III

Here is what the WD1007A supplies in response to the IDENTIFY DRIVE command:

Word  0: 0x324a
         Bit  1: Hard sectored
         Bit  3: Not MFM encoded
         Bit  6: Fixed drive
         Bit  9: Transfer rate > 5 Mbps but <= 10 Mbps
         Bit 12: Data strobe offset option
         Bit 13: Track offset option
Word  1: 969 (Fixed Cylinders)
Word  3: 9 (Heads)
Word  4: 20880 (Unformatted bytes per track)
Word  5: 580 (Unformatted bytes per sector)
Word  6: 36 (Sectors per track)
Word  7: 3088 (Bytes in inter-sector gap)
Word  8: 11 (Bytes in sync fields)
Word  9: 0xf (Vendor Unique)
Word 10-19: "00000000000000000000" (Serial Number)
Word 20: 3 (Buffer Type)
         dual ported multi-sector buffer with read caching
Word 21: 32 (Buffer Size in 512-byte Increments)
         16.0 KB
Word 22: 7 (Bytes of ECC)
Word 23-26: "REV. X3 " (Firmware Revision)
Word 27-46: "WD1007                                " (Model)
Word 47: 0x1 (Max Sectors per Interrupt)
         1 Sectors per Interrupt

Here’s the complete dump.

It is worth noting that the first ten words (0-9) come directly from the ESDI drive; the rest is supplied by the controller. And for ESDI drives, all the words and bits have specific meaning, which is not really the case with ATA drives. Keep in mind that with a different drive attached to the controller, the first 10 words could be completely different.

The rest of the IDENTIFY data comes from the controller. It is interesting that the controller supplies a dummy serial number. It obviously has no way to get the serial number out of the drive, but it fills the string with ASCII zero characters rather than leaving it empty.

The model is that of the controller, not the drive. Again, the controller has no way to query the drive. There is also a small but not tiny (16 KB) buffer on the controller.

And here’s what the WD1007V-SE2 controller returns with the same drive:

Word  0: 0x324a
         Bit  1: Hard sectored
         Bit  3: Not MFM encoded
         Bit  6: Fixed drive
         Bit  9: Transfer rate > 5 Mbps but <= 10 Mbps
         Bit 12: Data strobe offset option
         Bit 13: Track offset option
Word  1: 969 (Fixed Cylinders)
Word  3: 9 (Heads)
Word  4: 20880 (Unformatted bytes per track)
Word  5: 580 (Unformatted bytes per sector)
Word  6: 36 (Sectors per track)
Word  7: 3088 (Bytes in inter-sector gap)
Word  8: 11 (Bytes in sync fields)
Word  9: 0xf (Vendor Unique)
Word 10-19: "00000000000000000000" (Serial Number)
Word 20: 3 (Buffer Type)
         dual ported multi-sector buffer with read caching
Word 21: 64 (Buffer Size in 512-byte Increments)
         32.0 KB
Word 22: 4 (Bytes of ECC)
Word 23-26: "REV. A5 " (Firmware Revision)
Word 27-46: "WD1007V                               " (Model)
Word 47: 0x1 (Max Sectors per Interrupt)
         1 Sectors per Interrupt

Here’s the complete dump.

Other than the model and firmware revision, it’s essentially identical; the one difference is that the WD1007V has twice the buffer size, 32 KB. That’s as big or bigger than many early ATA drives.

The controllers report a different ECC size (4 vs. 7 bytes); that is a difference in how they’re jumpered, since they are both switchable.

In both cases, the controller reports the expected geometry data from the drive. Note that 9 heads is the true geometry (the ST4182E uses a dedicated servo surface).

It is kind of sad that since about 1986, ATA drives as well as AT-compatible ESDI controllers supported the IDENTIFY DRIVE command and thus provided everything needed for self-configuring firmware (and operating systems). But it took many years before BIOSes finally learned to automatically detect and configure ATA drives.

This entry was posted in ESDI, IDE, PC hardware, PC history, Western Digital. Bookmark the permalink.

19 Responses to IDENTIFY ESDI DRIVE

  1. SweetLow says:

    >buffer on the drive
    On the controller probably?

  2. Michal Necasek says:

    Oops, thanks! Of course, on the controller, the drive can’t easily have any.

  3. Octocontrabass says:

    It’s been a while since I looked at the WD1007V firmware, but I’m pretty sure it always reports the drive’s physical geometry, even when using the “alternate sector” option to reduce the drive’s capacity. You would have to add a special case to recognize the WD1007V and check the jumpers (in the last word of IDENTIFY DRIVE) to determine the usable sectors per track.

    Actually, looking at the pictures, I think you’ve enabled the alternate sector option on your WD1007V.

    There may have also been some kind of problem if the controller’s geometry translation were enabled, but I would have to dig up my notes again to check.

  4. Michal Necasek says:

    Hah, the NT 4.0 atapi.sys DDK source code has comments about a “hideous hack […] to deal with ESDI devices that return garbage geometry in the IDENTIFY data.” I bet that’s it (it talks about “Compaq ESDI” which was almost certainly a WD controller).

  5. Octocontrabass says:

    There’s also this comment in ATDISK.C:

    “The controller’s IDENTIFY command does not always return the correct number of sectors. The number observed was 1 too high on a Compaq Deskpro 386/16.”

    Which lines up pretty nicely with enabling the spare sector on a WD controller.

  6. Michal Necasek says:

    Yes, it does. Also running NT on a Deskpro 386/16 must have been excruciatingly painful.

    Anyway this is an interesting case where an ESDI controller looks so much like IDE that an OS has trouble with it.

  7. Yuhong Bao says:

    Did the Deskpro 386/16 even support more than 16MB of RAM?

  8. MiaM says:

    Interesting post!

    Octocontrabass: I’ve seen exactly that problem on a Deskpro 386/20 with a 60MB half height 5.25″ Conner IDE drive. Linux tried to access an extra non-existing sector. (I’m sure that many who follow this blog has heard about this particular drive too many times now).

    Also the Seagate/CDC Wren drive in this blog post seems to be configurable to use 34,35,36 or 63 sectors, yet the sectors per track word is 36 which is incorrect as compared to almost every IDE disk as the sector numbers start counting at 0 rather than 1.

    Michal: If you are prepared to run some more tests with that controller and drive, it would be interesting to know what parameters a Linux kernel thinks the drive has.

    Yuhong Bao:
    IIRC there is one slot for a special memory expansion card and that in turn has room for three smaller cards that just contain the actual chips for 4MB each. So depending on if the motherboard has 1MB or 4MB you would get 13 or 16MB max. Not sure if there were motherboards with 4MB, and also there might had been 1MB versions of those smaller cards. On the other hand I also don’t know if it was possible to move the start address of the 32-bit ram so that you could also have 16-bit ISA RAM. If so you could perhaps reach 32MB.

    Not that it really matters, the even NT 4 itself without a bunch of corporate bloatware runs fine on 16MB, so I bet that NT 3.x would run fine with even less memory. The CPU speed would likely be a bigger problem, but then I’ve never tried NT4 on anything less than a 486.

  9. Yuhong Bao says:

    NT had a minimum of about 12MB from the beginning.

  10. Michal Necasek says:

    A Conner IDE drive by definition can’t have a WD ESDI controller! That said… Conner never made 5.25″ drives, so maybe it was an ESDI drive? I can’t find any 5.25″ HH CDC ESDI drive that small, but there could well have been one from another manufacturer.

    Then again, I can’t find any such drive. 60 MB is kind of small for ESDI, they tended to be much higher capacity. An ESDI drive in a Compaq Deskpro 386/20 certainly would not be at all surprising, but I can’t find any drive that would be close to 60 MB and can’t find any evidence Compaq sold such drives. Can you remember more details?

    The sector numbers start at 1, not 0. Cylinders and heads start at 0, sectors don’t. That is true of floppies, ST-506 compatible drives, as well as IDE drives.

    The issue with the IDENTIFY DRIVE command on those ESDI drives was that the drive was possibly configurable, but then the controller could reserve one sector per track or translate geometry, and that was not reflected in the IDENTIFY DRIVE data, since that came straight from the drive.

  11. Richard Wells says:

    The Infoworld article on the Compaq 386/20 indicates that the 60MB drive used was MFM ST-412 model. The drive still had better seek performance than the 70MB ESDI drive IBM was making.

    Sector numbers on some of the ESDI drives started at 0. That was the whole trick to creating a spare sector on the track that the system couldn’t see. Amazing how computers continued to expect the design limitations of early IBM tape drives; the IBM tape could not save a value with only zero bits so all the record counts started with a value of one.

  12. MiaM says:

    I’m 100% sure that it was an IDE drive as it was both possible to connect a newer larger drive to the existing controller and cable in the Deskpro, and also connect this older drive to an IDE port of a newer computer. I’m also 100% sure that the computer was a Compaq 386DX (although the DX part might not had been invented when it was manufactured). I’m 99% sure that in addition to the expected ports on the rear of a XT/AT style case it also had a three pin DIN connector supplying 12V DC for what I would assume would be a monochrome monitor. (12″ black/white TVs at the time did consume about 1A at 12V so it would make sense to use the computers power supply, especially since in Europe each of the countries that required electric safety certification would have different certification procedures. Sweden didn’t require certification for office equipment at the time, but other countries did and it would had been a requirement if they would ever sell to an individual rather than a company so they may had had it certified anyways).

    I’m 99% sure that it had a grey front cover, which I think makes it a later of the first Deskpro 386 series. IIRC it also had a tape streamer and at least one disk drive, maybe both 5.25″ and 3.5″.

    I’m 100% sure that it was a 5.25″ IDE drive, that was the thing that made it stand out the most, and I’m also 100% sure that it reported one too many of one of the parameters, and 99% sure it was the number of sectors. I might misremember but I think the number of sectors indicated that it would use the regular MFM or possible RLL encoding rather than the many more sectors per track/head an ESDI disk usually has.

    Unless we find something like a Compaq spare parts list or a field service manual not older than the last date the original Deskpro 386 stopped selling I would say that it’s not possible to rule out it being a Conner. Usually the material archived about various stuff are what was offered initially or perhaps when some major updates were done, but changing the front panel color from black to gray and switching from MFM/ESDI disks to IDE disks might not had ended up in the magazines or even the brochures at all, especially not the disk type.

    Technically it might had been a 5.25″ third height drive made by Conner and a whichever-to-IDE-adapter made by WD if that would make any more sense? I don’t think it did look like any double stacked cobbled together thing like those “cakes” with a 5.25″ MFM disk on top of a SASI-MFM interface seen in older equipment.

    And the story that no one might find interesting is that I could had still had this computer. I was offered various old tech junk while helping a friend move, but a pile of stuff didn’t fit in the car and at the next load-and-move iteration another friend of my friend helped out instead of me, and it ended up in the trash. Now may years later the Deskpro was the biggest loss but it was a bit unfortunately that a decent pair of 1970’s Philips speakers also ended up in the trash, although those now and then show up in thrift stores for about 10-30 EUR so no economical loss there. Btw, not 100% but there is a slight chance that I have the keyboard from the Deskpro though.

    Btw re sector numbers, have anyone in this thread read the IDE spec recently enough that they know for sure that the identify drive command should return the number of sectors as is or subtracted by one? Even if the actual sector number parameter uses the number as-is starting at one, the identify drive command spec might spec that the sectr count should start at 0, perhaps to match the track counter and whatnot? If so, hard to tell what idea they might had had, but for example they might want to had avoided 0 in the ident command but still be able to use 64 sectors, and let the actual commands where you specify sector have 0 mean 64. That of course never happened but it could had been part of the thought process if they specified it this way.

    Or if the ident command indeed is correct for your ESDI drive and so on, it might had been that the 60MB drive I’m refering to just had a off-by-one problem for some reason.

    Re the main topic, that we could had had auto identification, it would be interesting to know about when almost all users stopped using MFM/RLL drives? And also, how would most of those controllers react to the IDENTIFY command? Were there any MFM or RLL controllers that would react badly if you would try that command? Sure, for the most parts I would assume that companies would just buy a new computer rather than upgrade in increments, but I remember that as a home user it was common to buy parts separate and me and some friends bought used parts and put them together to form a decent PC. I for example clearly remember buying a used 20MB MFM disk and a used AT MFM+floppy controller card in the early 90’s. Not 100% sure but I think that at some point in time that setup were used with a 386DX40 motherboard, so way older disks than the motherboard.

  13. Michal Necasek says:

    Yes, but the spare sectors with ID 0 were inaccessible, intentionally outside of the valid sector number range.

    ETA: I bet the IW article was wrong. The Compaq Type 47 60MB drive used a geometry with 25 sectors per track and 5 heads. That can’t be MFM, and it would be unusual even for an RLL drive.

  14. Michal Necasek says:

    The thing is, Conner never made 5.25″ drives. There is one small exception, the Chinook (SCSI) drive, but that was an extremely exotic drive and you would definitely remember that. Conner’s whole thing was 3.5″ drives with integrated controllers. Conner did make “OEM specials” that do not show in their model lists, but I dare say if they provided Compaq with 5.25″ drives, we’d know about it.

    The only 5.25″ IDE drives available in the Deskpro 386 times that I’m aware of were CDC/Imprimis/Seagate Wren II HH. The ST274A was a 5.25″ HH IDE drive with about 65 MB formatted capacity. I’m almost sure Compaq used those or something very similar.

    The big switch from MFM/RLL to ATA happened sometime around 1991. It happened very quickly because that was when “modern” IDE drives reached the mass market, with things like zoned recording and the associated increase in capacity.

    On old controllers, the IDENTIFY DRIVE command will just fail, nothing bad will happen.

    The IDENTIFY DRIVE command was always specified to return the number of heads/cylinders/sectors per track (so that if you multiply them, you get the total capacity). It is possible that some drive did it wrong.

  15. Michal Necasek says:

    I’ve done a bit more digging. In 1988, Compaq definitely did offer a Deskpro 386/20 Model 60 with a 60MB hard disk. It was actually the entry level model. The hard disk was an “integrated” 1:1 interleave drive, and was CMOS type 47. See the hard disk types table here, the drive used geometry with 25 sectors per track which is actually pretty unusual.

    I cannot figure out what that drive was. All I know is that it wasn’t a Conner CP30061G (60MB), which is Type 55. It was almost certainly an IDE drive but I can’t even find if it was a 5.25″ drive or not.

    Oh wait, hang on a sec… I’ve got it! The drive was a CDC/Imprimis 94208-75. See photos here, further evidence here (Type 47 disk). I actually first found the Compaq part number (108058-001) here.

    Are you still certain that it was a Conner?

  16. MiaM says:

    Bingo, it must had been that CDC/Imprimis 94208-75! Sorry for getting you on the wrong track by misremembering it as a Conner.

    Did Compaq order the disks with their own label without the CDC/Imprimis branding? If so I might incorrectly just had assumed that it was a Conner with a thought process that probably was something like “It’s an IDE disk so it can’t be any of the brands that went away before the 90’s, and it doesn’t look like a Seagate or WD at all, so therefore it must be a Conner”. I can’t remember any Seagate where the main metal case were black and it had separate unpainted metal sides, and the WD disks I can remember had an unpainted top cover that almost protruded around the edges.

  17. Michal Necasek says:

    Hard to say without seeing photos. If your drive was from 1988, it was quite likely made before they started the Imprimis brand, and the old CDC drives were somewhat nondescript to begin with. It is entirely possible that a Compaq OEM drive was labeled such that the drive manufacturer was not easy to discern.

    Sadly these drives (94208-75 and 94208-51) are completely undocumented and I could not find them even mentioned in CDC documentation. They could well have been OEM-only models, supplied to Compaq and no one else. Conner did that kind of thing a lot and the OEM models do not show up in Conner’s drive lists.

    The drives are Wren II HH and as such must be close relatives of the 94204-81 and 94204-74 aka Seagate ST280A and ST274A. My ST280A is clearly different because it reports 27 sectors per track, not 25 or 26. Interestingly it looks like the older 94204-51 and 94208-75 drives were mechanically identical but the smaller 40MB model used MFM and the bigger 60MB drive used RLL format.

  18. techfury90 says:

    I had a Deskpro 386 (16MHz, had an 80287 fitted from the factory and an empty 80387 socket) in my possession about a decade and a half ago with an Imprimis 94208-51 in it. At least I’m guessing it’s the -51, I recall the drive being approximately 40MB formatted, so it would fit. I distinctly recall the drive being labeled Imprimis, with the famous label style you’ve covered in a past blog post.

  19. Michal Necasek says:

    I’d have loved to get my hands on that drive. The 94208-51 was probably the first “real” IDE drive (not a MFM drive with a controller bolted on). Interesting that the drive was Imprimis branded, it was probably a replacement because by the time the Imprimis brand started, the 16 MHz Deskpro was obsolete.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.