# MIC_AdjustAutoSamplingAsync

## C Specification

  `#include <nitro/spi.h>`

      MICResult MIC_AdjustAutoSamplingAsync(
                  u32             rate,
                  MICCallback     callback,
                  void*           arg );

## Arguments

rate | The sampling rate. Directly specifies the CPU timer rate of the ARM7. Can also be selected from enumerated-type `MICSamplingRate`.
callback | Specifies the pointer to the callback function. This callback is called from within the interrupt handler.
arg | Specifies the argument passed to the callback function.

## Return Values

Returns the enumerated-type `MICResult` process result. If the asynchronous process started normally, returns `MIC_RESULT_SUCCESS`. If the process fails for some reason, returns some other value.

## Description

Asynchronously adjusts the sampling rate of the microphone's auto-sampling.
This is only valid when auto-sampling has already begun. When ARM7 receives the request, the CPU timer cycle gets updated.
This function issues an auto-sampling adjustment request to ARM7, waits for a response from ARM7, and returns the process result.
You need to get the process result from the ARM7 via the `result` argument passed to the user callback function. If this function fails, asynchronous operations are not performed and the user callback function cannot be called.

## See Also

`MIC_AdjustAutoSampling`, `MIC_StartAutoSamplingAsync`, `MIC_StopAutoSamplingAsync`

## Revision History

06/27/2005 Added additional text indicating that the callback is called from the interrupt handler.
01/11/2005 Initial version