fatfs v0.09b Jan 23,2013:
- Added f_getlabel() and f_setlabel(). (_USE_LABEL == 1)
This commit is contained in:
1 parent
030f12c942
commit
750225eb33
112 files changed
+1847
-1043
No files matched your search
+13
-13
@@ -13,12 +13,12 @@
|
||||
|
||||
<div class="para func">
|
||||
<h2>disk_ioctl</h2>
|
||||
<p>The disk_ioctl function cntrols device specified features and miscellaneous functions other than disk read/write.</p>
|
||||
<p>The disk_ioctl function cntrols device specific features and miscellaneous functions other than generic read/write.</p>
|
||||
<pre>
|
||||
DRESULT disk_ioctl (
|
||||
BYTE <em>Drive</em>, <span class="c">/* Drive number */</span>
|
||||
BYTE <em>Command</em>, <span class="c">/* Control command code */</span>
|
||||
void* <em>Buffer</em> <span class="c">/* Parameter and data buffer */</span>
|
||||
BYTE <span class="arg">pdrv</span>, <span class="c">/* [IN] Drive number */</span>
|
||||
BYTE <span class="arg">cmd</span>, <span class="c">/* [IN] Control command code */</span>
|
||||
void* <span class="arg">buff</span> <span class="c">/* [I/O] Parameter and data buffer */</span>
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
@@ -26,12 +26,12 @@ DRESULT disk_ioctl (
|
||||
<div class="para arg">
|
||||
<h4>Parameters</h4>
|
||||
<dl class="par">
|
||||
<dt>Drive</dt>
|
||||
<dt>pdrv</dt>
|
||||
<dd>Specifies the drive number (0-9).</dd>
|
||||
<dt>Command</dt>
|
||||
<dt>cmd</dt>
|
||||
<dd>Specifies the command code.</dd>
|
||||
<dt>Buffer</dt>
|
||||
<dd>Pointer to the parameter buffer depends on the command code. When it is not used, specify a NULL pointer.</dd>
|
||||
<dt>buff</dt>
|
||||
<dd>Pointer to the parameter buffer depends on the command code. Set NULL if not used.</dd>
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
@@ -44,7 +44,7 @@ DRESULT disk_ioctl (
|
||||
<dt>RES_ERROR</dt>
|
||||
<dd>Any error occured.</dd>
|
||||
<dt>RES_PARERR</dt>
|
||||
<dd>Invalid command code.</dd>
|
||||
<dd>Invalid command code or parameter.</dd>
|
||||
<dt>RES_NOTRDY</dt>
|
||||
<dd>The disk drive has not been initialized.</dd>
|
||||
</dl>
|
||||
@@ -57,10 +57,10 @@ DRESULT disk_ioctl (
|
||||
<table class="lst">
|
||||
<tr><th>Command</th><th>Description</th></tr>
|
||||
<tr><td>CTRL_SYNC</td><td>Make sure that the disk drive has finished pending write process. When the disk I/O module has a write back cache, flush the dirty sector immediately. This command is not used in read-only configuration.</td></tr>
|
||||
<tr><td>GET_SECTOR_SIZE</td><td>Returns sector size of the drive into the WORD variable pointed by <tt>Buffer</tt>. This command is not used in fixed sector size configuration, <tt>_MAX_SS</tt> is 512.</td></tr>
|
||||
<tr><td>GET_SECTOR_COUNT</td><td>Returns number of available sectors on the drive into the DWORD variable pointed by <tt>Buffer</tt>. This command is used by only f_mkfs function to determine the volume size to be created.</td></tr>
|
||||
<tr><td>GET_BLOCK_SIZE</td><td>Returns erase block size of the flash memory in unit of sector into the DWORD variable pointed by <tt>Buffer</tt>. The allowable value is 1 to 32768 in power of 2. Return 1 if the erase block size is unknown or disk devices. This command is used by only f_mkfs function and it attempts to align data area to the erase block boundary.</td></tr>
|
||||
<tr><td>CTRL_ERASE_SECTOR</td><td>Erases a part of the flash memory specified by a DWORD array {<start sector>, <end sector>} pointed by <tt>Buffer</tt>. When this feature is not supported or not a flash memory media, this command has no effect. The FatFs does not check the result code and the file function is not affected even if the sectors are not erased well. This command is called on removing a cluster chain when <tt>_USE_ERASE</tt> is 1.</td></tr>
|
||||
<tr><td>GET_SECTOR_SIZE</td><td>Returns sector size of the drive into the <tt>WORD</tt> variable pointed by <tt class="arg">buff</tt>. This command is not used in fixed sector size configuration, <tt>_MAX_SS</tt> is 512.</td></tr>
|
||||
<tr><td>GET_SECTOR_COUNT</td><td>Returns number of available sectors on the drive into the <tt>DWORD</tt> variable pointed by <tt class="arg">buff</tt>. This command is used by only <tt>f_mkfs()</tt> function to determine the volume size to be created.</td></tr>
|
||||
<tr><td>GET_BLOCK_SIZE</td><td>Returns erase block size of the flash memory in unit of sector into the <tt>DWORD</tt> variable pointed by <tt class="arg">buff</tt>. The allowable value is 1 to 32768 in power of 2. Return 1 if the erase block size is unknown or disk devices. This command is used by only <tt>f_mkfs()</tt> function and it attempts to align data area to the erase block boundary.</td></tr>
|
||||
<tr><td>CTRL_ERASE_SECTOR</td><td>Erases a part of the flash memory specified by a <tt>DWORD</tt> array {<start sector>, <end sector>} pointed by <tt class="arg">buff</tt>. This is similar command to Trim command of ATA command set. When this feature is not supported or not a flash memory media, this command has no effect. The FatFs does not check the result code and the file function is not affected even if the sectors are not erased well. This command is called on removing a cluster chain when <tt>_USE_ERASE</tt> is 1.</td></tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in new issue
Block a user