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=utf-8">
6<META http-equiv="Content-Style-Type" content="text/css">
7<LINK rel="stylesheet" type="text/css" href="../CSS/revolution.css">
8<title>NANDCloseAsync</title>
9</head>
10
11<body>
12
13<h1>NANDCloseAsync</h1>
14
15<h2>Syntax</h2>
16<dl><dd><pre class="construction">
17#include &lt;revolution/nand.h&gt;
18
19typedef void (*NANDCallback)( s32 result, NANDCommandBlock *block );
20
21s32 NANDCloseAsync( NANDFileInfo *info, NANDCallback cb, NANDCommandBlock *block );
22</pre></dd></dl>
23
24<h2>Arguments</h2>
25<p>
26<TABLE class="arguments" border="1" >
27  <tr>
28<TH>info</TH>
29<TD>Pointer to a <CODE>NANDFileInfo</CODE> structure.</TD>
30  </tr>
31  <tr>
32<TH>cb</TH>
33<TD>Callback function to call when this function completes processing.</TD>
34  </tr>
35  <tr>
36<TH>block</TH>
37<TD>Command block structure to be passed to the callback function.</TD>
38  </tr>
39</TABLE>
40</p>
41
42<h2>Return Values</h2>
43<p>
44The result codes that may be returned by <code>NANDCloseAsync</code> are listed below. Returns <CODE>NAND_RESULT_OK</CODE> when the request begins normally.
45<p>
46<code>NAND_RESULT_OK<br> NAND_RESULT_ACCESS<br> NAND_RESULT_ALLOC_FAILED<br> NAND_RESULT_BUSY<br> NAND_RESULT_INVALID<br> NAND_RESULT_FATAL_ERROR<br></code>
47</p>
48<p>
49The result codes that may be passed to the callback function are listed below.
50</p>
51<p>
52<code>NAND_RESULT_OK<br> NAND_RESULT_ACCESS<br> NAND_RESULT_CORRUPT<br> NAND_RESULT_INVALID<br> NAND_RESULT_UNKNOWN<br> NAND_RESULT_FATAL_ERROR<br></code>
53</p>
54</p>
55
56<H2>Description</H2>
57<p>
58Asynchronously closes a file. <code>NAND_RESULT_BUSY</code> is returned and this function call is denied when the queue for accepting requests inside the library is full.
59</p>
60
61<p>
62This function updates the FAT of the Wii console NAND memory. However, updating does not take place if a file is being closed and no data has been written to the files in Wii console NAND memory since the last time the FAT was updated.
63</p>
64
65<h2>See Also</h2>
66<p class="reference">
67<a href="./NANDOpen.html">NANDOpen</a><BR><a href="./NANDOpenAsync.html">NANDOpenAsync</a><BR><a href="./NANDClose.html">NANDClose</a>
68</p>
69
70<H2>Revision History</H2>
71<p>
722009/12/02 Added information about updating the FAT.<br>2008/08/01 Revised the result codes that are passed to the callback function.<br>2008/05/13 Described the result codes passed to the callback function.<br>2008/04/23 Commented about updating the FAT.<br>2006/06/16 Initial version.<BR>
73</p>
74
75<hr><p>CONFIDENTIAL</p></body>
76</html>
77