Tugger the SLUGger!SLUG Mailing List Archives

Re: [SLUG] Formating a USB Floppy


On Thu, Feb 08, 2001 at 11:48:08AM +0900, Antony Stace wrote:

> doesn't want to work....

No, sorry, my fault.  fdformat does a low-level format, which I didn't
know (thanks Ken), mkdosfs just creates the filesystem.  I thought you
were just trying to create the filesystem.

fdformat only works on devices with a major number of 2.  You can't
simply delete this check and recompile the program, because the
format mechanism is different.

Standard floppy controllers format track-by-track, that is, they need
to be told to format each track in turn.  SCSI devices, however, have a
format command which formats the entire device at once.  IIRC, you need
to specify the device parameters in the format command.

I was thinking that it'd be fairly easy to write a SCSI format program,
but I needed some information to do so.  A quick google search turned
up this:

    http://pantransit.reptiles.org/prog/archive/scsifmt.c
    
According to the comments, it's supposed to check that the device is
a Zip drive, but although there's code present to do that check, the
function is never called.  The only thing I'm not sure of is whether
it needs to be changed to pass tracks/sectors/heads/sector size in
the format command.  I don't have a SCSI floppy drive on which to
test it ...


Cheers,

John
-- 
Any sufficiently advanced technology is indistinguishable from a rigged
demo.