• Published on | Jun 14, 2015 | by Chris Osborn

Emulating an old HP-IB disk drive with HPDrive

It'll never work like that! I bought a National Instruments AT-GPIB IEEE-488 ISA card last year intending to use it with HPDrive so that I could make an old PC pretend to be an HP-IB hard disk. I installed the HP-IB card in the old KT7A-RAID computer I’ve been using for doing lots of other retro things. Unfortunately the card had to go all the way at the end and the HP-IB connector was too large to fit on there which meant swapping the motherboard into a different case that didn’t have the card bay recessed. Of course after doing the case swap I got distracted with something else and set the project aside. While in the process this week of starting to clean up my electronics workbench to convert my game back into a game room, I had enough space again to do come back to the HPDrive and HP-IB project.
 
I pulled out the HP 9000/360 (link to previous article here) and connected the HP-IB cable up to the PC. I ran the HPDrive program and told it to emulate a 7937H 571MB drive and netbooted the 9000 into NetBSD. It wasn’t immediately obvious that NetBSD saw anything, but digging through the logs I found a message that it had identified a 7937H drive with 1116102 blocks and had set it up as /dev/rd0.
 
I was able to use dd to write some data to the emulated drive and read it back. However since I couldn’t successfully find a way to get NetBSD to format the disk, I got out the HP 150 to see if I could get the HP 150 to format an emulated disk. I hooked up the real 9133D and HPDrive and booted the HP 150. After several attempts to format an emulated 9134H drive and failing I gave up. It either failed during the format, or if I chose a smaller 9134D disk size, it would fail when it started copying files.
 
After struggling to get the emulated drive to format, I had another idea! Why not hook up the real 9133D and see if I can use dd to make an image of it? I disconnected the 9133D from the HP 150 and hooked it up to the 9000 and booted everything up. The 9000 saw the drive and after a bit of searching to figure out that under NetBSD a raw device is /dev/rd0c I let dd go to it. After several minutes I had a 19 meg file, however dd wasn’t stopping. I force killed dd and examined the file with hexdump. As I paged through it I could see that it had the filenames I would expect, even though somehow the image was larger than the actual drive.
 
It boots! I truncated the disk image and copied it over to the PC with the HP-IB card and started HPDrive in 9134D mode using the image I pulled from the real drive. With the HP 150 hooked up to the PC, I fired it up to see what would happen. The HP 150 booted up!
 

Join The Discussion