Struct ns_audio_cfg
#include <ns_audio.h>
Public Attributes
Type | Name |
---|---|
const ns_core_api_t * | api API prefix. |
ns_audadc_cfg_t * | audadc_config |
void * | audioBuffer Where the audio will be located when callback occurs. |
void * | audioSystemHandle Handle, filled by init. |
ns_ipc_ring_buffer_t * | bufferHandle Filled by init. |
ns_audio_callback_cb | callback Invoked when there is audio in buffer. |
ns_audio_api_mode_e | eAudioApiMode |
ns_audio_source_e | eAudioSource Choose audio source such as AUDADC. |
float | fLGAdB |
uint8_t | numChannels Number of audio channels, currently 1 or 2. |
uint16_t | numSamples Samples collected per callback. |
ns_pdm_cfg_t * | pdm_config |
am_hal_offset_cal_coeffs_array_t * | sOffsetCalib |
am_hal_pdm_transfer_t | sTransfer |
uint32_t * | sampleBuffer Where samples are DMA'd to. |
uint16_t | sampleRate In Hz. |
void * | workingBuffer Not used for Apollo4 Lite. |
Detailed Description
NeuralSPOT Audio API Configuration Struct
Audio configuration is via this struct, which also serves as a handle after ns_audio_init() has been invoked
Public Attributes Documentation
variable api
const ns_core_api_t* ns_audio_cfg::api;
variable audadc_config
ns_audadc_cfg_t* ns_audio_cfg::audadc_config;
AUDADC Config - only used by audadc driver
variable audioBuffer
void* ns_audio_cfg::audioBuffer;
variable audioSystemHandle
Handle, filled by init.
void* ns_audio_cfg::audioSystemHandle;
Internals
variable bufferHandle
ns_ipc_ring_buffer_t* ns_audio_cfg::bufferHandle;
variable callback
Invoked when there is audio in buffer.
ns_audio_callback_cb ns_audio_cfg::callback;
IPC
variable eAudioApiMode
ns_audio_api_mode_e ns_audio_cfg::eAudioApiMode;
Defines how the audio system will interact with the applications
variable eAudioSource
Choose audio source such as AUDADC.
ns_audio_source_e ns_audio_cfg::eAudioSource;
Audio Config
variable fLGAdB
float ns_audio_cfg::fLGAdB;
variable numChannels
uint8_t ns_audio_cfg::numChannels;
variable numSamples
uint16_t ns_audio_cfg::numSamples;
variable pdm_config
ns_pdm_cfg_t* ns_audio_cfg::pdm_config;
PDM Config - only used by the pdm driver
variable sOffsetCalib
am_hal_offset_cal_coeffs_array_t* ns_audio_cfg::sOffsetCalib;
variable sTransfer
am_hal_pdm_transfer_t ns_audio_cfg::sTransfer;
variable sampleBuffer
uint32_t* ns_audio_cfg::sampleBuffer;
variable sampleRate
uint16_t ns_audio_cfg::sampleRate;
variable workingBuffer
void* ns_audio_cfg::workingBuffer;
The documentation for this class was generated from the following file neuralSPOT/neuralspot/ns-audio/includes-api/ns_audio.h