Getting 2nd Floppy disk controller working
Before I elaborate on the problem; this is the solution I want to get working. Please don't advise on alternative solutions.
The PC's onboard FDC has :
1 x 3.5" 2.88Mb FDD
1 x 5.25" 360K FDD
The FDC on an Adaptec 1542B has :
1 x 5.25" 1.2Mb FDD
There is a reason why the drives are connected as they are, and it centres round adding a Catweasel PCI card further down the line.
Basically; the Adaptec's FDC will function as the primary FDC (using IO-port 3F0h), but not as a secondary FDC (using IO-port 370h).
I've checked /proc/ioports, and I can see that there is no contention for 370h
I'm told that the two FDCs are happy to share the same IRQ
Short of trying a different distro, I'm at a loss.
The floppy support is via a kernel module, and I'm typing :
modprobe floppy floppy=two_fdc
....the command works, but the 2nd FDC isn't picked up.
I suspect I'm not entering the command correctly, and the documentation isn't particularly clear :
Sets the CMOS type of <drive> to <type>. This is mandatory if you have more than two floppy drives (only two can be described in the physical CMOS), or if your BIOS uses non-standard CMOS types. The CMOS types are:
0 - Use the value of the physical CMOS
1 - 5 1/4 DD
2 - 5 1/4 HD
3 - 3 1/2 DD
4 - 3 1/2 HD
5 - 3 1/2 ED
6 - 3 1/2 ED
16 - unknown or not installed
....how do you express "drive" ? I'm assuming fd0 (or fd1, fd2, fd3)
Anyway, at this stage, I'm only concerned about getting the two FDCs picked up, so I've only got a single 1.44Mb 3.5" FDD on each controller.
I've defined both FDDs in the motherboard's BIOS, but then it halts on the POST screen with a floppy failure. If I remove "B:" from the motherboard's BIOS, then it'll boot fine.
The Adaptec card doesn't need to have the aha1542 module loaded for the floppy controller - because it worked as a primary FDC with just the floppy module loaded.
O.S I've been using on this particular PC is "System Rescue CD". No reason to think that another distro could succeed where SR CD has failed. Got FreedDOS as well, but I don't know if I need to play with the CONFIG.SYS to get the 2nd FDC recognised.
So...in summary; mobo FDC disabled, Adaptec FDC works as primary when jumpered for 3F0h. Re-enable mobo's FDC, jumper Adaptec FDC for 370h, and it fails to get recognised as a secondary FDC.
Does someone know the exact parameters I should be passing to the modprobe floppy command ?
Thanks in advance
Something that occurred to me....
Does a PC's BIOS still recognise a second FDC ? I know that Linux doesn't need BIOS support for the second FDC, but if the PC's BIOS should detect two FDCs, then I've got a hardware issue. If I have a single 1.44Mb FDD connected to each controller, and I set "A:" and "B:" in the mobo's BIOS; I get a "Failed floppy disk(s)" error on the POST screen :-(
The mobo is a socket A/462 board, which dates back to 2001. I opted for this board, as it has 1 ISA slot for the Adaptec 1542B, leaving me 5 available PCI slots (GFX is via AGP)
using old ISA bus hardware is a bit out-dated now.
No-one uses floppy disk drives. They are not very reliable also.
Suggesting that floppy disks are obsolete and unreliable isn't helpful. I have a need to read a variety of different disk types (3.5" and 5.25") and formats (DOS, Amiga, C64 etc). This is the solution I want to get working, and I know it is technically possible. Just a question of hitting on the right parameters for the "modprobe floppy" command.
I'm running a live CD - System Rescue CD
I've worked out what the parameters should be for the modprobe floppy command :
modprobe floppy "floppy=4,4,cmos"
....for a 1.44Mb FDD connected to the secondary FDC
Mobo BIOS handles the first two drives - fd0 and fd1, so no need to specify them.
Still can't get the secondary FDC recognised :-(
Things I'm going to try :
Another ISA card with FDC that will function at 0x370
possibly another distro
You might be better off getting one of the USB floppy drives.
That's why I said at the start of this thread that I didn't want alternative solutions suggested. This is the only solution I'm interested in getting working.
You can get a 2.88MB usb drive. Here is one of many a quick google search turned up.
You can also use the usb to 1.44mb interface (via a standard 5-1/4 to 3.5 adapter) to run a 5-1/4 drive. Thus the Catweasel would not be needed.
So running both is a perfectly viable option.
In order to read Amiga, C64 etc disks, I need both a 360k 5.25" drive and a 3.5" drive (DD/HD/ED) on the primary FDC, with the catweasel in between the FDC and the drives.
The secondary FDC is for a 1.2Mb 5.25" FDD
A 1.44 MB floppy drive and a 1.2 MB floppy drive are backwards compatible for reading and writing to smaller formats, so you just need two drives. Formatting is another issue. If you insist on using more than two floppy drives and your card is ISA, you have to know the IRQ that are taken up. What you have been told is wrong when dealing with legacy hardware. ISA devices can not share IRQ. PCI can share IRQ, but only if they support it and this is an "IF." ACPI corrects this issue by extending the amount of IRQs to a few dozen. Setting up ISA cards are a trial-n-error process while PCI, AGP, PCI-X, and PCIe (PCI Express) are still plug-n-pray.
Have had partial success.
I've configured the AHA-1542b as follows :
IRQ : 10
DMA : 3
IO : 0x370
The motherboard's FDC takes the standard resources :
IRQ : 6
DMA : 2
IO : 3F0
I boot up "System Rescue CD", and can get the floppy module talking to either of the FDCs. Just not at the same time :-(
If I type :
....I can access fd0 and fd1 on the primary FDC, and the relevant device files are created under /dev. The floppy module gets the FDD types from the BIOS.
If I then type :
modprobe floppy "floppy=3,dma 10,irq 4,4,cmos"
....I can access fd4 (which is currently a 1.44Mb 3.5"), and the relevant device files are created under /dev. The floppy module needs to be told what type of drive fd4 is, as it can't get the information from the BIOS.
My problem now is; how can I load the floppy module such that I can specify the DMA and IRQ for both FDCs ? The "two_fdc" option won't detect both controllers; it seems to want to know the IRQ and DMA. The "dma" and "irq" parameters for the floppy module don't seem to allow you to specify more than one irq/dma combination.
It transpires that the floppy module (as is) doesn't support specifying more than one IRQ/DMA pair. So; unless the floppy module sees both FDCs on the same IRQ and DMA, you can't get both to work. The maintainer of the floppy kernel module (and FD-Utils) is going to provide a patch to floppy.c later this month, such that you'll be able to specify a second IRQ/DMA pair; along the lines of :
modprobe floppy "floppy=two_fdc 2,dma 6,irq 3,dma2 10,irq2....."
Will report back on any progress. At least I know that my hardware is okay, and that I was using the correct syntax for the "modprobe floppy" command.
|All times are GMT -5. The time now is 03:47 AM.|