Okay, I guess I probably could start posting here again, no reason not to. I am writing a floppy driver for my OS, and I'm having problems with the interrupts. My OS handles interrupt perfectly, I have never had problems with interrupts in any other part of it.
When I start writing my floppy driver, I follow examples of what other people have done, and do basically the exact same thing as they do (seeing as there's limited ways to do the same thing). I get an interrupt signaled when I reset the floppy disk, but never at any other time such as a seek command or a recalibrate. Anybody have any clues?
Floppy driver problems
-
- Member
- Posts: 31
- Joined: Thu Apr 14, 2005 11:00 pm
- Location: Planet Earth
- Contact:
See my driver in this post and see if you have miss some thing
http://www.osdev.org/phpBB2/viewtopic.php?t=12041
http://www.osdev.org/phpBB2/viewtopic.php?t=12041
I had exactly the same problem and it nearly drove me to the point of insanity!!! the solution for me was a really n00b coding error when sending commands to the floppy controller in my sendbyte and getbyte functions.
Before you send a command e.g. seek, recalibrate etc you must make sure the main status register is in the correct mode i.e. RQM and DIO are set to either 1,0 for writing and 1,1 for reading.
Also after you have recieved an interrupt dont forget to send the sense interrupt command to acknowledge it. Check the intel floppy datasheet diagrams at the bottom for more details on doing that 4 times to clear flags for each drive.
Hope that helps,
Lon
Before you send a command e.g. seek, recalibrate etc you must make sure the main status register is in the correct mode i.e. RQM and DIO are set to either 1,0 for writing and 1,1 for reading.
Also after you have recieved an interrupt dont forget to send the sense interrupt command to acknowledge it. Check the intel floppy datasheet diagrams at the bottom for more details on doing that 4 times to clear flags for each drive.
Hope that helps,
Lon
-
- Member
- Posts: 31
- Joined: Thu Apr 14, 2005 11:00 pm
- Location: Planet Earth
- Contact: