## disk_status

The disk_status function gets the disk status.

    DSTATUS disk_status (
      BYTE Drive     /* Physical drive number */
    );

#### Parameters

Drive
  Specifies the physical drive number to be tested.

#### Return Values

The disk status is returned in combinatin of following flags.

STA_NOINIT
  Indicates that the disk drive has not been initialiezed. This flag is set on: power-on, disk removal and disk_initialize function failed, and cleared on: disk_initialize function succeeded.
STA_NODISK
  Indicates that no medium in the drive. It is always cleared on fixed disk drive.
STA_PROTECTED
  Indicates that the medium is write protected. It is always cleared on the drive that does not support write protect notch.

Return