From efa13a879df590ce0043a5b4f97597484bf264e1 Mon Sep 17 00:00:00 2001 From: inmarket Date: Wed, 13 Aug 2014 15:48:16 +1000 Subject: Move 3rd Party source to a new directory. Rationalise Fatfs code and fix a couple of configuration issues. --- 3rdparty/fatfs-0.10b/doc/en/dwrite.html | 76 +++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 3rdparty/fatfs-0.10b/doc/en/dwrite.html (limited to '3rdparty/fatfs-0.10b/doc/en/dwrite.html') diff --git a/3rdparty/fatfs-0.10b/doc/en/dwrite.html b/3rdparty/fatfs-0.10b/doc/en/dwrite.html new file mode 100644 index 00000000..616acf68 --- /dev/null +++ b/3rdparty/fatfs-0.10b/doc/en/dwrite.html @@ -0,0 +1,76 @@ + + + + + + + + +FatFs - disk_write + + + + +
+

disk_write

+

The disk_write writes sector(s) to the storage device.

+
+DRESULT disk_write (
+  BYTE drv,         /* [IN] Physical drive number */
+  const BYTE* buff, /* [IN] Pointer to the data to be written */
+  DWORD sector,     /* [IN] Sector number to write from */
+  UINT count        /* [IN] Number of sectors to write */
+);
+
+
+ +
+

Parameters

+
+
pdrv
+
Physical drive number to identify the target device.
+
buff
+
Pointer to the byte array to be written. The size of data to be written is sector size * count bytes.
+
sector
+
Start sector number in logical block address (LBA).
+
count
+
Number of sectors to write. FatFs specifis it in range of from 1 to 128.
+
+
+ + +
+

Return Values

+
+
RES_OK (0)
+
The function succeeded.
+
RES_ERROR
+
Any hard error occured during the write operation and could not recover it.
+
RES_WRPRT
+
The medium is write protected.
+
RES_PARERR
+
Invalid parameter.
+
RES_NOTRDY
+
The device has not been initialized.
+
+
+ + +
+

Description

+

The specified memory address is not that always aligned to word boundary because the type of pointer is defined as BYTE*. For more information, refer to the description of disk_read() function.

+

Generally, a multiple sector transfer request must not be split into single sector transactions to the storage device, or you will never get good write throughput.

+

FatFs expects delayed write feature of the disk functions. The write operation to the media need not to be completed due to write operation is in progress or only stored it into the cache buffer when return from this function. But data on the buff is invalid after return from this function. The write completion request is done by CTRL_SYNC command of disk_ioctl() function. Therefore, if delayed write feature is implemented, the write throughput may be improved.

+

Application program MUST NOT call this function, or FAT structure on the volume can be collapsed.

+
+ + +
+

QuickInfo

+

This function is not needed when _FS_READONLY == 1.

+
+ + +

Return

+ + -- cgit v1.2.3