disk_write

The disk_write writes sector(s) to the disk.

DRESULT disk_write (
  const BYTE* Buffer,  // Pointer to the data to be written.
  DWORD SectorNumber,  // Sector number to write.
  BYTE SectorCount     // Number of sectors to write.
);

Parameters

Buffer
Pointer to the data to be written.
SectorNumber
Specifies the sector number in logical block address to write from.
SectorCount
Specifies number of sectors to write. The value can be 1 to 255.

Return Values

RES_OK
The function succeeded.
RES_ERROR
Any error occured during read operation.
RES_WRPRT
The disk is write protected.
RES_PARERR
Invalid parameter.
RES_NOTRDY
The disk dirve has not been initialized.

Description

This function is not required in read only configuration.

Return