1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<html>
3
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
6<META http-equiv="Content-Style-Type" content="text/css">
7<LINK rel="stylesheet" type="text/css" href="../CSS/revolution.css">
8<title>NANDGetAvailableArea</title>
9</head>
10
11<body>
12
13<h1>NANDGetAvailableArea</h1>
14
15<h2>Syntax</h2>
16<dl><dd><pre class="construction">#include &lt;revolution/nand.h&gt;
17
18s32 NANDGetAvailableArea( u32 *fsBlock, u32 *inode );
19</pre></dd></dl>
20
21<h2>Arguments</h2>
22<p>
23<TABLE class="arguments" border="1" >
24  <tr>
25<TH>fsBlock</TH>
26<TD>Pointer to a u32 type variable. Stores the usable FS block count (0 &#x2266; *<SPAN class="argument">fsBlock</SPAN> &#x2266; 1024).</TD>
27  </tr>
28  <tr>
29<TH>inode</TH>
30<TD>Pointer to a u32 type variable. Stores the usable inode count (0 &#x2266; *<SPAN class="argument">inode</SPAN> &#x2266; 32).</TD>
31  </tr>
32</TABLE>
33</p>
34
35<h2>Return Values</h2>
36<p>
37Returns one of the following codes.
38<p>
39<code>
40NAND_RESULT_OK<br>
41NAND_RESULT_ALLOC_FAILED<br>
42NAND_RESULT_BUSY<br>
43NAND_RESULT_INVALID<br>
44NAND_RESULT_UNKNOWN<br>
45NAND_RESULT_FATAL_ERROR<br>
46</code>
47</p>
48</p>
49
50<h2>Description</h2>
51<p>
52Gets the upper limit of the number of FS blocks and inodes of the files/directories that can be created (under the home directory) by the application program. The upper limit in the home directory is set to 16MB and 32 inodes, respectively. The range of values that can be obtained through this function is as shown in the above table. Even if the application has not created anything in the home directory, the values obtained through this function will be small if most of the user area is used by other applications.
53</p>
54<p>
55This function essentially provides the same features as <a href="./NANDCheck.html"><CODE>NANDCheck</CODE></a>. But if you want to inform the player about availability of Wii console NAND memory when creating new files/directories, use this function.
56</p>
57
58<p>
59This function may put the current thread to sleep. For precautions when calling similar functions, refer to <a href="../os/Interrupt/intro.html">Interrupts and Callback Functions</a>.
60</p>
61
62<h2>See Also</h2>
63<p class="reference">
64<a href="./NANDGetAvailableAreaAsync.html">NANDGetAvailableAreaAsync</a>,
65<a href="./NANDCheck.html">NANDCheck</a>,
66<a href="./NANDCheckAsync.html">NANDCheckAsync</a>,
67<a href="./NANDFreeBlocks.html">NANDFreeBlocks</a>,
68<a href="./NANDFreeBlocksAsync.html">NANDFreeBlocksAsync</a>,
69<a href="../os/Interrupt/intro.html">Interrupts and Callback Functions</a>
70</p>
71
72<h2>Revision History</h2>
73<p>
742007/09/25 Added information about the sleep status of threads.<br>2006/11/30 Added the <CODE>NAND_RESULT_ALLOC_FAILED</CODE> and <CODE>NAND_RESULT_BUSY</CODE> codes.<br>2006/11/30 Deleted text about being an alternative to <CODE>NANDCheck[Async]</CODE>.<br>2006/10/25 Initial version.<br>
75</p>
76
77<hr><p>CONFIDENTIAL</p></body>
78</html>