5. IDE Command Descriptions
33
Seek (7xh)
This command initiates a seek and selects the head specified in the command block.
The drive need not be formatted for a seek command to execute properly.
When the command is issued, the drive sets BSY in the status register, initiates the
seek, resets BSY, and generates an interrupt. Only the cylinder register is valid for this
command. The drive does not wait for the seek to complete before returning the
interrupt. Seek complete is set upon completion of the command. If a new command is
issued to a drive while a seek is being executed, the drive will wait, with BSY active, for
the seek to complete before executing the new command.
No checks are made on the validity of the sector number in the command block. The
error bit in the status register and the ID Not Found bit in the error register of the
command block is set if an illegal cylinder number is passed.
Execute Drive Diagnostic (90h)
This command performs internal diagnostic tests implemented by the drive. The
diagnostic tests are executed only upon receipt of this command.
The drive sets BSY immediately upon receipt of the command. If the drive is a master it
performs the diagnostic tests and saves the results. The drive then checks for the
presence of a slave drive and waits for up to five seconds for the slave to complete its
diagnostics. The slave asserts PDIAG when its diagnostics are successfully completed.
If the slave does not successfully complete its diagnostics the error register is set. The
master drive resets BSY and generates an interrupt. The value in the error register
should be viewed as a unique 8-bit code and not as a single-bit flag. The interface
registers, except for the error register, are set to initial values. The following table,
"Error Register Codes", defines the codes in the error register.
Error Register Codes
Error Code
Description
5l 01
no error detected
03
sector buffer error
8x
slave drive failed
Note:
If the slave drive fails diagnostics, the master drive will "OR" 80h with its own
status and load that code into the error register. If the slave drive passes diagnostics or
there is no slave drive connected, the master drive will set bit 7 of the error register in
the command block to 0.
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com