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

testing "USB-ZIP" images in an emulated environment

10 views
Skip to first unread message

Mateusz Viste

unread,
Mar 17, 2021, 5:08:58 AM3/17/21
to
Hello fellow programmers,

I am fiddling a little bit with building a bootable USB image with DOS
on it. So far I learned that there are 3 modes of USB booting:

* USB-HDD: the most common it seems, where the BIOS uses USB storage to
emulate a normal hard disk (DL=0x80 at boot time). The USB drive must
have a proper MBR for this to work, once booted under DOS the drive
appears as "C:". I was able to test this one on my laptop and it works.

* USB-FDD: as far as I understand, this works by simply writing a floppy
image to the USB device, ie. no MBR, only the FAT12 fs is present on
the USB drive. Some obscure sources say that for this mode to work, the
USB drive should present itself with a name that hints as a floppy
vendor... I don't have any way of testing this so I can only wonder.

* USB-ZIP: emulated ZIP-100 or ZIP-250 drive. Requires a specially
crafted MBR where only partition 4 is being used and its CHS geometry
must mimic an actual ZIP drive (64 heads, 32 sectors, 96 cylinders). It
would seem (?) that in this mode, the BIOS skips the MBR bootstrap and
loads the VBR right away. Once booted to DOS, the drive is epxected to
appear as "A:" (ie. DL=0).

Now my problem is much more practical: none of the PCs I have support
booting in either USB-ZIP nor USB-FDD modes, so I wonder how I could
test it.

Any idea how these modes (esp. USB-ZIP, as that's the one I am most
interested in) could be tested in a virtualized environment? I have read
the QEMU manual but did not find anything that would hint at QEMU
providing support for such USB booting. Did anyone here investigate
this subject in the past already? Any hints welcome!

Mateusz

JJ

unread,
Mar 17, 2021, 3:40:24 PM3/17/21
to
I don't think every motherboard BIOS/firmware support that booting
emulation. Because not every motherboard BIOS/firmware support ZIP/LS-120
drives. And most of all, such booting emulation is non standard. The only
standard for boot emulation is the El-Torito specification - which is for
optical drive.

Also, drive type is determined by hardware. In the device's firmware. So,
once a modern OS is loaded, it will bypass motherboard BIOS/firmware, thus
bypass the emulation.

QEMU's BIOS doesn't support ZIP drive. You'll have to find and use other
BIOS which at least support ZIP drive in its BIOS configuration. Preferably
those from a real machine.

Rod Pemberton

unread,
Mar 18, 2021, 7:02:57 PM3/18/21
to
On Wed, 17 Mar 2021 10:08:56 +0100
There were some conversations on this on alt.os.development a few years
back.

Specifically, I never could get USB-FDD to work correctly for MS-DOS.
USB-HDD eventually worked, but not for the machine I wanted. This
implied that the BIOS emulation on one of the machines was flawed.

From a post of mine to a.o.d. in 2017, there was some more info on each
of the three modes:

"
USB-FDD is DL=0, no MBR, no partition, apparently needs a correct
device name, e.g., manufacturer's name of a physical floppy device

USB-ZIP is DL=0, one partition, boots VBR directly, skips boot code, 63
head/32 sectors preferred, translates disk calls from start of the
partition which hides data prior to the partition start, may need to
modify values in the VBR to boot correctly

USB-HDD is DL=80h, two partitions, or it may auto-select USB-ZIP with
only one partition for some BIOSes
"

Apparently, I found a clue indicating that there is a specification for
the modes out there somewhere.

--
Clinton: biter. Trump: grabber. Cuomo: groper. Biden: mauler.

0 new messages