source: xtideuniversalbios/trunk/XTIDE_Universal_BIOS/Inc/Int13h.inc@ 197

Last change on this file since 197 was 150, checked in by Tomi Tilli, 14 years ago

Changes to XTIDE Universal BIOS:

  • Redesigned Disk Parameter Tables.
  • Code generalizations for supporting non-IDE devices in the future.
File size: 2.1 KB
RevLine 
[150]1; Project name : XTIDE Universal BIOS
[3]2; Description : Equates used in INT 13h functions.
3%ifndef INT13H_INC
4%define INT13H_INC
5
6; Hard Disk function (INT 13h) return status codes in AH
7RET_HD_SUCCESS EQU 0h ; Operation succesfull, no error occurred
8RET_HD_INVALID EQU 1h ; Invalid value passed or unsupported func
9RET_HD_ADDRMARK EQU 2h ; Missing address mark
10RET_HD_WRITEPROT EQU 3h ; Removable media is write protected
11RET_HD_NOT_FOUND EQU 4h ; Requested sector not found
12RET_HD_RESETFAIL EQU 5h ; Reset failed
13RET_HD_CHANGED EQU 6h ; Media changed
14RET_HD_PARAMACT EQU 7h ; Drive parameter activity failed
15RET_HD_OVERRUN EQU 8h ; DMA overrun
16RET_HD_BOUNDARY EQU 9h ; Data boundary error
17RET_HD_BADSECTOR EQU 0Ah ; Bad sector detected
18RET_HD_BADTRACK EQU 0Bh ; Bad track detected
19RET_HD_UNCORRECC EQU 10h ; Uncorrectable ECC error
20RET_HD_ECC EQU 11h ; Corrected ECC error
21RET_HD_CONTROLLER EQU 20h ; Hard disk controller or drive problem
22RET_HD_NOMEDIA EQU 31h ; No media in removable media drive
23RET_HD_SEEK_FAIL EQU 40h ; Seek operation failed
24RET_HD_TIMEOUT EQU 80h ; Drive failed to respond
25RET_HD_NOTREADY EQU 0AAh ; Drive is not ready or is not selected
26RET_HD_NOTLOCKED EQU 0B0h ; Volume not locked in drive
27RET_HD_LOCKED EQU 0B1h ; Volume locked in drive
28RET_HD_NOTREMOVABLE EQU 0B2h ; Volume not removable
29RET_HD_INUSE EQU 0B3h ; Volume in use
30RET_HD_LOCKEXCEEDED EQU 0B4h ; Lock count exceeded
31RET_HD_EJECTFAIL EQU 0B5h ; Valid eject request failed
32RET_HD_UNDEFINED EQU 0BBh ; Undefined error occurred
33RET_HD_WRFAULT EQU 0CCh ; Write fault on selected drive
34RET_HD_STATUSERR EQU 0E0h ; Status error without error
35RET_HD_SENSEFAIL EQU 0FFh ; Sense operation failed
36
37
38; Floppy Drive types returned by INT 13h, AH=08h
39FLOPPY_TYPE_525_OR_35_DD EQU 0
40FLOPPY_TYPE_525_DD EQU 1
41FLOPPY_TYPE_525_HD EQU 2
42FLOPPY_TYPE_35_DD EQU 3
43FLOPPY_TYPE_35_HD EQU 4
44FLOPPY_TYPE_35_ED EQU 6
45
46
[150]47MAX_SUPPORTED_BLOCK_SIZE_IN_SECTORS EQU 64
48
49%define TIMEOUT_AND_STATUS_TO_WAIT(timeout, status) (((timeout)<<8) | (status))
50
51
[3]52%endif ; INT13H_INC
Note: See TracBrowser for help on using the repository browser.