In message <[EMAIL PROTECTED]>, Warner Losh writ
es:
>
>That's OK.  The Rainbow disks have sectors numbered 1 through 10, for
>both CP/M disks and MS-DOS disks.  This makes things easier to cope
>with.

Great, then no driver changes are required. I've just tried it; I
found a normal PC 5.25" drive, and I was able to read the DEC
Rainbow boot disk I have here by doing

        # fdcontrol /dev/fd1
        sectrac? []: 10
        secsize? [2]:
        datalen? [0xff]:
        gap? [0x1b]:
        tracks? [80]:
        size? []: 800
        steptrac? [1]:
        trans? []: 1
        heads? []: 1
        f_gap? [0x54]:
        f_inter? [1]:

        # hd /dev/fd1 |less

Note: The `trans' values come from the 'FDC_???KBPS' #defines in
fdreg.h. A value of 1 is 'FDC_300KBPS' which is different to the
specs you quoted, but I think the PC standard 5.25" drive runs at
360rpm rather than 300. For a 300rpm drive you probably want a
trans value of 2 (250kbps).

I just left the `gap' and `f_gap' values at their defaults; I don't
know the exact details of these fields, but I seem to remember that
they are only used during writing and formatting, so you can ignore
them for reading.

>for this project.  Any thumbnail about how to add a new type of drive
>to fd.c?  What parameters do I need for it?

You could add an entry to the fd_types array in fd.c, but that
requires linking the entry into a device node, so it's probably
easier to just use fdcontrol.

Ian

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to