1e6865dcdSopenharmony_ci<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2e6865dcdSopenharmony_ci<html lang="en">
3e6865dcdSopenharmony_ci<head>
4e6865dcdSopenharmony_ci<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
5e6865dcdSopenharmony_ci<meta http-equiv="Content-Style-Type" content="text/css">
6e6865dcdSopenharmony_ci<link rel="up" title="FatFs" href="../00index_e.html">
7e6865dcdSopenharmony_ci<link rel="alternate" hreflang="ja" title="Japanese" href="../ja/dinit.html">
8e6865dcdSopenharmony_ci<link rel="stylesheet" href="../css_e.css" type="text/css" media="screen" title="ELM Default">
9e6865dcdSopenharmony_ci<title>FatFs - disk_initialize</title>
10e6865dcdSopenharmony_ci</head>
11e6865dcdSopenharmony_ci
12e6865dcdSopenharmony_ci<body>
13e6865dcdSopenharmony_ci
14e6865dcdSopenharmony_ci<div class="para func">
15e6865dcdSopenharmony_ci<h2>disk_initialize</h2>
16e6865dcdSopenharmony_ci<p>The disk_initialize function is called to initializes the storage device.</p>
17e6865dcdSopenharmony_ci<pre>
18e6865dcdSopenharmony_ciDSTATUS disk_initialize (
19e6865dcdSopenharmony_ci  BYTE <span class="arg">pdrv</span>           <span class="c">/* [IN] Physical drive number */</span>
20e6865dcdSopenharmony_ci);
21e6865dcdSopenharmony_ci</pre>
22e6865dcdSopenharmony_ci</div>
23e6865dcdSopenharmony_ci
24e6865dcdSopenharmony_ci<div class="para arg">
25e6865dcdSopenharmony_ci<h4>Parameter</h4>
26e6865dcdSopenharmony_ci<dl class="par">
27e6865dcdSopenharmony_ci<dt>pdrv</dt>
28e6865dcdSopenharmony_ci<dd>Physical drive number to identify the target device. Always zero at single drive system.</dd>
29e6865dcdSopenharmony_ci</dl>
30e6865dcdSopenharmony_ci</div>
31e6865dcdSopenharmony_ci
32e6865dcdSopenharmony_ci
33e6865dcdSopenharmony_ci<div class="para ret">
34e6865dcdSopenharmony_ci<h4>Return Values</h4>
35e6865dcdSopenharmony_ci<p>This function returns the current drive status flags as the result. For details of the drive status, refer to the <a href="dstat.html">disk_status</a> function.</p>
36e6865dcdSopenharmony_ci</div>
37e6865dcdSopenharmony_ci
38e6865dcdSopenharmony_ci<div class="para desc">
39e6865dcdSopenharmony_ci<h4>Description</h4>
40e6865dcdSopenharmony_ci<p>This function initializes the storage device and put it ready to generic read/write. When the function succeeded, <tt>STA_NOINIT</tt> flag in the return value is cleared.</p>
41e6865dcdSopenharmony_ci<p><em>Remarks: This function needs to be under control of FatFs module. Application program MUST NOT call this function while FatFs is in use, or FAT structure on the volume can be broken. To re-initialize the filesystem, use <tt>f_mount</tt> function instead.</em></p>
42e6865dcdSopenharmony_ci</div>
43e6865dcdSopenharmony_ci
44e6865dcdSopenharmony_ci<p class="foot"><a href="../00index_e.html">Return</a></p>
45e6865dcdSopenharmony_ci</body>
46e6865dcdSopenharmony_ci</html>
47