Function 36h Get Disk Free Space
get information on specified drive
entry AH 36h
DL drive number (0=default, 1=A:, 2=B:, etc)
return AX number of sectors per cluster
0FFFFh means drive specified in DL is invalid
BX number of availible clusters
CX bytes per sector
DX clusters per drive
note 1) Mult AX * CX * BX for free space on disk
2) Mult AX * CX * DX for total disk space
3) Function 36h returns an incorrect value after an ASSIGN command. Prior
to ASSIGN, the DX register contains 0943h on return, which is the free
space in clusters on the HC diskette. After ASSIGN, even with no
parameters, 0901h is returned in the DX register; this is an incorrect
value. Similar results occur with DD diskettes on a PC-XT or a PC-AT.
This occurs only when the disk is not the default drive. Results are as
expected when the drive is the default drive. Therefore, the
circumvention is to make the desired drive the default drive prior to
issuing this function call.
4) Int 21h, function call 36h returns an incorrect value after an ASSIGN
command. Prior to ASSIGN, the DX register contains 0943h on return,
which is the free space in clusters on the HC diskette. After ASSIGN,
even with no parameters, 0901h is returned in the DX register; this is
an incorrect value. Similar results occur with DD diskettes on a PC-XT
or a PC-AT. This occurs only when the disk is not the default drive.
Results are as expected when the drive is the default drive. Therefore,
the circumvention is to make the desired drive the default drive prior
to issuing this function call.
5) This function supercedes functions 1Bh and 1Ch.