Changes

765 FDC

228 bytes added, Wednesday at 21:12
/* Accessing the FDC 765 */
== Accessing the FDC 765 ==
The Data Main Status Register (Port FB7Fh) signalizes when the FDC is used ready to write Commands and Parameters, to readsend/write data bytes, and to receive result bytes. These three operations are called Command-, Execution-, and Result-Phase :* Command Phase :A command consists of a command the next byte (eventually including through the MF, MK, SK bits), and up to 8 parameter bytesData Register.
* Execution Phase : During this phase, the actual data is transferred The Data Register (if anyPort FB7Fh). Usually that are the is used to write Commands and Parameters, to read/write data bytes for the read/written sector(s), except for the Format Track and to receive result bytes. These three operations are called Command-, in that case 4 bytes for each sector are transferredExecution-, and Result-Phase.
* Result === Command Phase : Returns up to 7 result bytes (depending on the command) that are containing status information. The Recalibrate and Seek Track commands do not return result bytes directly, instead the program must wait until the Main Status Register signalizes that the command has been completed, and then it must (!) send a Sense Interrupt State command to 'terminate' the Seek/Recalibrate command.===
During the result phase, all the result bytes must be read. The FDC will not accept A command consists of a new command until all byte (eventually including the result MF, MK, SK bits), and up to 8 parameter bytes are read.
=== Execution Phase === During this phase, the actual data is transferred (if any). Usually that are the data bytes for the read/written sector(s), except for the Format Track Command, in that case 4 bytes for each sector are transferred. During data transfers between the FDC and the processor, the FDC must me serviced every 26us (for MFM mode with CPC timings) or the FDC sets the Overrun flag in Status Register 1 and terminates the FDC command. === Result Phase === Returns up to 7 result bytes (depending on the command) that are containing status information. The Recalibrate and Seek Track commands do not return result bytes directly, instead the program must wait until the Main Status Register signalizes when that the FDC is ready to command has been completed, and then it must (!) senda Sense Interrupt State command to 'terminate' the Seek/receive Recalibrate command. During the next byte through result phase, all the Data Registerresult bytes must be read. The FDC will not accept a new command until all the result bytes are read.
<br>
5,719
edits