Copy an utterance to the specified buffer.
#include "asr/asrm.h"
int asrm_set_utterance(asr_module_hdl_t *mod, asr_audio_info_t *audio_info, uint32_t ms_offset)
A pointer to the module handle (for error logging).
A pointer to the structure in which to store the utterance.
The offset (in milliseconds) of the utterance.
The asrm_set_utterance() function copies the last captured audio sample to the buffer referenced by the audio_info parameter, at the offset specified by the ms_offset parameter. If the requested offset results in a buffer overrun, an error is returned. If the audio capture has not completed, an error is returned.
0 Success.
EBUSY Capture has not completed.
ENOMEM Buffer overrun or other memory error.