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 name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 8.0.0.0 for Windows"> 7<META http-equiv="Content-Style-Type" content="text/css"> 8<title>MIC_StartLimitedSamplingAsync</title> 9<LINK rel="stylesheet" href="../../css/nitro.css" type="text/css"> 10</head> 11 12<body> 13 14<h1 align="left">MIC_StartLimitedSamplingAsync <img src="../../image/TWL.gif"></h1> 15 16<h2>Syntax</h2> 17<dl> 18 <dd> 19<CODE>#include <twl/spi.h></CODE><BR> 20 <PRE><CODE><A href="MICResult.html">MICResult</A> MIC_StartLimitedSamplingAsync( 21 const <CODE><A href="MICAutoParam.html">MICAutoParam</A></CODE>* param, 22 <A href="MICCallback.html">MICCallback</A> callback, 23 void* arg );</CODE></PRE> 24 </dd> 25</dl> 26 27<h2>Arguments</h2> 28<TABLE border="1" width="100%"> 29 <TBODY> 30 <TR> 31 <TD width="300"><em><strong><font face="Courier New">param</font></strong></em></TD> 32 <TD width="700">Specifies a pointer to a <CODE><A href="MICAutoParam.html">MICAutoParam</A></CODE>-type auto-sampling settings structure.</TD> 33 </TR> 34 <TR> 35 <TD><em><strong><font face="Courier New">callback</font></strong></em></TD> 36 <TD>Specifies the pointer to the callback function. This callback is called from within the interrupt handler.</TD> 37 </TR> 38 <TR> 39 <TD><em><strong><font face="Courier New">arg</font></strong></em></TD> 40 <TD>Specifies the argument passed to the callback function.</TD> 41 </TR> 42 </TBODY> 43</TABLE> 44 45<h2>Return Values</h2> 46<P> 47Returns the processing result as a <CODE><A href="MICResult.html">MICResult</A></CODE> enumerated type. Returns <CODE>MIC_RESULT_SUCCESS</CODE> if the asynchronous process started normally; returns some other value if the process failed. 48</P> 49 50<H2>Description</H2> 51<P> 52Asynchronously starts frequency-limited microphone auto-sampling. This function issues a request to the ARM7 to start frequency-limited auto-sampling, then returns control to the caller without waiting for a response. You must use the <CODE>result</CODE> argument passed by the user callback function to get the ARM7 processing result. If this function fails, the asynchronous operation is not performed and the user callback function is not called.<BR>Where the input volume exceeds the minimum or maximum value, the output data will be clamped. 53</P> 54<P> 55Frequency-limited auto-sampling differs from normal auto-sampling in that the hardware does the actual sampling. As a result, stable sampling can be performed at precise cycles; also, by relaxing the CPU burden on the ARM7, effects of sampling on wireless communications and other I/O will be reduced. On the other hand, sampling cannot be performed at frequencies that are unsupported by the hardware. The following sampling frequencies can be specified for <CODE>param</CODE> <CODE>->rate</CODE>, but the frequencies that can be specified at a given time depend on the sound master frequency settings and thus are further limited to four of the following. A value of <CODE>MIC_RESULT_ILLEGAL_PARAMETER</CODE> will be returned if one of the limited frequencies is not specified. 56</P> 57<TABLE border="1" width="100%"> 58 <TBODY> 59 <TR> 60 <TH width="20%"><center>Sound master frequency</center></TD> 61 <TH width="40%"><center>Settable frequency</center></TD> 62 <TH width="40%"><center>Description</center></TD> 63 </TR> 64 <TR> 65 <TD rowspan="4">32.73kHz</TD> 66 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_32730</font></strong></em></TD> 67 <TD>32.73kHz (1/1 of the master frequency)</TD> 68 </TR> 69 <TR> 70 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_16360</font></strong></em></TD> 71 <TD>16.36kHz (1/2 of the master frequency)</TD> 72 </TR> 73 <TR> 74 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_10910</font></strong></em></TD> 75 <TD>10.91kHz (1/3 of the master frequency)</TD> 76 </TR> 77 <TR> 78 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_8180</font></strong></em></TD> 79 <TD>8.18kHz (1/4 of the master frequency)</TD> 80 </TR> 81 <TR> 82 <TD rowspan="4">47.61kHz</TD> 83 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_47610</font></strong></em></TD> 84 <TD>47.61kHz (1/1 of the master frequency)</TD> 85 </TR> 86 <TR> 87 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_23810</font></strong></em></TD> 88 <TD>23.81kHz (1/2 of the master frequency)</TD> 89 </TR> 90 <TR> 91 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_15870</font></strong></em></TD> 92 <TD>15.87kHz (1/3 of the master frequency)</TD> 93 </TR> 94 <TR> 95 <TD><em><strong><font face="Courier New">MIC_SAMPLING_RATE_11900</font></strong></em></TD> 96 <TD>11.90kHz (1/4 of the master frequency)</TD> 97 </TR> 98 </TBODY> 99</TABLE> 100 101<H2>Note</H2> 102<P> 103<FONT color=red>Because frequency-limited auto-sampling cannot be performed on the NITRO platform or when the CODEC is running in CODEC-DS mode, this function will instead internally call the <CODE><A href="MIC_StartAutoSamplingAsync.html">MIC_StartAutoSamplingAsync()</A></CODE> auto-sampling control function.</FONT> 104</P> 105<P><FONT color=red>It has been confirmed that slight hardware noise is mixed with the microphone input on the TWL console. See <A href="./about_HardwareNoise.html">here</A> for a workaround.</FONT></P> 106<H2>See Also</H2> 107<P> 108<CODE><A href="MIC_StartLimitedSampling.html">MIC_StartLimitedSampling</A>, <A href="MIC_StopLimitedSamplingAsync.html">MIC_StopLimitedSamplingAsync</A>, <A href="MIC_AdjustLimitedSamplingAsync.html">MIC_AdjustLimitedSamplingAsync</A></CODE> 109</P> 110 111<H2>Revision History</H2> 112<P> 1132008/01/09 Added a note about the difference in behavior with CODEC mode. <BR>2007/11/17 Initial version.<BR> 114</P> 115<hr><p>CONFIDENTIAL</p></body> 116</html> 117