1<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<HTML> 3 <HEAD> 4 <META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 5 <title>SNDEX_GetI2SFrequencyAsync</title> 6 <link rel="stylesheet" href="../../css/nitro.css" type="text/css"> 7 </HEAD> 8 <BODY> 9 <H1>SNDEX_GetI2SFrequencyAsync <IMG src="../../image/TWL.gif" width="24" height="12" border="0" align=middle></H1> 10 11 <H2>Syntax</H2> 12 <DL> 13 <DD><CODE>#include <twl/snd.h></CODE></DD> 14 <DD><PRE><CODE>SNDEXResult SNDEX_GetI2SFrequencyAsync( <A href="SNDEXFrequency.html">SNDEXFrequency</A>* freq, <A href="SNDEXCallback.html">SNDEXCallback</A> callback, void* arg );</CODE></PRE></DD> 15 </DL> 16 17 <H2>Arguments</H2> 18 <TABLE> 19 <TBODY> 20 <TR> 21 <TH width="25%"><SPAN class="argument">freq</SPAN></TH> 22 <TD width="75%">Pointer to a variable that will get the I2S operating frequency as an <A href="SNDEXFrequency.html"><CODE>SNDEXFrequency</CODE></A> enumerated type. A value is written to this variable asynchronously, so it must not be used for anything else until asynchronous processing is complete.</TD> 23 </TR> 24 <TR> 25 <TH width="25%"><SPAN class="argument">callback</SPAN></TH> 26 <TD width="75%"><A href="SNDEXCallback.html"><CODE>SNDEXCallback</CODE></A>-type function that is notified when the asynchronous process has completed. The asynchronous process runs even if <CODE>NULL</CODE> is specified here, but you are no longer able to detect that it has completed.</TD> 27 </TR> 28 <TR> 29 <TH width="25%"><SPAN class="argument">arg</SPAN></TH> 30 <TD width="75%">Argument to pass to the function specified in <SPAN class="argument">callback</SPAN>.</TD> 31 </TR> 32 </TBODY> 33 </TABLE> 34 35 <H2>Return Values</H2> 36 <H3>Function Return Values</H3> 37 <TABLE> 38 <TBODY> 39 <TR> 40 <TH width="25%"><CODE>SNDEX_RESULT_SUCCESS</CODE></TH> 41 <TD width="75%">Asynchronous processing started successfully. The asynchronous processing results are passed as an argument to the function registered in <SPAN class="argument">callback</SPAN>.</TD> 42 </TR> 43 <TR> 44 <TH width="25%"><CODE>SNDEX_RESULT_ILLEGAL_STATE</CODE></TH> 45 <TD width="75%">This function has been called on the NITRO platform.</TD> 46 </TR> 47 <TR> 48 <TH width="25%"><CODE>SNDEX_RESULT_BEFORE_INIT</CODE></TH> 49 <TD width="75%">Extended sound features have not been initialized by the <A href="SNDEX_Init.html"><CODE>SNDEX_Init</CODE></A> function.</TD> 50 </TR> 51 <TR> 52 <TH width="25%"><CODE>SNDEX_RESULT_EXCLUSIVE</CODE></TH> 53 <TD width="75%">Processing for other extended sound features is running. Note that mutexes are used for each of the extended sound features, so they cannot be used simultaneously.<BR>As mentioned in the <A href="./doc/aboutSNDEX.html">SNDEX Library Overview</A>, the error also returns during processing of shutter sound playback.</TD> 54 </TR> 55 <TR> 56 <TH width="25%"><CODE>SNDEX_RESULT_PXI_SEND_ERROR</CODE></TH> 57 <TD width="75%">A PXI command failed to be sent to the ARM7. This error occurs when the PXI send queue for the ARM7 has filled up or when the hardware has detected an error. As a result, the state may improve when a retry is made.</TD> 58 </TR> 59 </TBODY> 60 </TABLE> 61 <H3>Asynchronous Process Results</H3> 62 <TABLE> 63 <TBODY> 64 <TR> 65 <TH width="25%"><CODE>SNDEX_RESULT_SUCCESS</CODE></TH> 66 <TD width="75%">The whole series of operations completed successfully.</TD> 67 </TR> 68 <TR> 69 <TH width="25%"><CODE>SNDEX_RESULT_EXCLUSIVE</CODE></TH> 70 <TD width="75%">A mutex error occurred in the ARM7. This error depends upon the progress of ARM7 processing, so conditions may improve when a retry is made.</TD> 71 </TR> 72 <TR> 73 <TH width="25%"><CODE>SNDEX_RESULT_FATAL_ERROR</CODE></TH> 74 <TD width="75%">This error should not ordinarily occur. This may occur when an illegal PXI command was sent directly, ignoring library state management; when the ARM7 component and the extended sound feature library have different versions; when library state management has fallen into an abnormal state due to memory corruption; or when other such conditions arise. There is no way to recover from this at run time. 75 </TD> 76 </TR> 77 </TBODY> 78 </TABLE> 79 80 <H2>Description</H2> 81 <P> 82 Asynchronously gets the I2S operating frequency. 83 </P> 84 <P> 85 If this function does not return a value of <CODE>SNDEX_RESULT_SUCCESS</CODE>, the asynchronous processing and callback will not be run. Also note that a PXI receive interrupt will send notification when the asynchronous processing is complete, so callbacks will not occur if PXI receive interrupts are prohibited. 86 </P> 87 88 <H2>See Also</H2> 89 <P> 90 <A href="SNDEX_GetI2SFrequency.html"><CODE>SNDEX_GetI2SFrequency</CODE></A><BR> <A href="SNDEX_SetI2SFrequencyAsync.html"><CODE>SNDEX_SetI2SFrequencyAsync</CODE></A> 91 </P> 92 93 <H2>Revision History</H2> 94 <P> 952008/11/07 Added mention that <CODE>SNDEX_RESULT_EXCLUSIVE</CODE> is returned during processing of shutter sound playback.<BR> 2008/11/06 Corrected <B>Asynchronous Process Results</B> (<CODE>SNDEX_RESULT_EXCLUSIVE</CODE>) in <B>Return Values</B>.<BR> 2008/02/15 Initial version. 96 </P> 97 <hr><p>CONFIDENTIAL</p></body> 98</HTML> 99