Programming the Floppy Disk Controller
Posted: Fri Apr 04, 2008 10:36 am
I've just finished to program my fdc driver.
When I've tested it, it has worked on bochs (and I started jumping for the happiness), then on VMWare.
Here's the problem.
On VMWare it's like the interrupt never arrives. This happends on Resetting the fdc:
the "true" at the end of some outportb stands for "inportb(80)" so there is a little delay...
Does anyone know why it doesn't work?
Thanks
When I've tested it, it has worked on bochs (and I started jumping for the happiness), then on VMWare.
Here's the problem.
On VMWare it's like the interrupt never arrives. This happends on Resetting the fdc:
Code: Select all
void Floppy::Reset(Bit32u base, char drive) {
outportb(base + FLOPPY_DOR, 0x00, true); //Disable the controller
outportb(base + FLOPPY_RSR, 0x00, true); //Rate: 500Kb/s
outportb(base + FLOPPY_DOR, 0x0C, true); //Enable the controller
cpu.waitForInterrupt(38); //IT FREEZES HERE!!!
{
int st0, cyl;
CheckInterrupt(base, &st0, &cyl);
}
outportb(base + FLOPPY_CCR, 0x00, true);
ConfigureDrive(base);
CalibrateDrive(base, drive);
}
Does anyone know why it doesn't work?
Thanks