<p>The f_getcwd function retrieves the current directory.</p>
<pre>
FRESULT f_getcwd (
TCHAR* <spanclass="arg">buff</span>, <spanclass="c">/* [OUT] Buffer to return path name */</span>
UINT <spanclass="arg">len</span><spanclass="c">/* [IN] The length of the buffer */</span>
);
</pre>
</div>
<divclass="para arg">
<h4>Parameters</h4>
<dlclass="par">
<dt>buff</dt>
<dd>Pointer to the buffer to receive the current directory string.</dd>
<dt>len</dt>
<dd>Size of the buffer in unit of TCHAR.</dd>
</dl>
</div>
<divclass="para ret">
<h4>Return Values</h4>
<p>
<ahref="rc.html#ok">FR_OK</a>,
<ahref="rc.html#de">FR_DISK_ERR</a>,
<ahref="rc.html#ie">FR_INT_ERR</a>,
<ahref="rc.html#nr">FR_NOT_READY</a>,
<ahref="rc.html#ne">FR_NOT_ENABLED</a>,
<ahref="rc.html#ns">FR_NO_FILESYSTEM</a>,
<ahref="rc.html#tm">FR_TIMEOUT</a>,
<ahref="rc.html#nc">FR_NOT_ENOUGH_CORE</a>
</p>
</div>
<divclass="para desc">
<h4>Description</h4>
<p>The <tt>f_getcwd()</tt> function retrieves full path name of the current directory of the current drive. When <tt>_VOLUMES</tt> is larger than 1, a logical drive number is added to top of the path name.</p>