XCORE SDK
XCORE Software Development Kit
Modules | Classes | Typedefs | Enumerations | Functions
rtos_mic_array_driver

Modules

 rtos_mic_array_driver_core
 
 rtos_mic_array_driver_rpc
 

Classes

struct  rtos_mic_array_struct
 

Typedefs

typedef struct rtos_mic_array_struct rtos_mic_array_t
 

Enumerations

enum  rtos_mic_array_format_t { RTOS_MIC_ARRAY_CHANNEL_SAMPLE , RTOS_MIC_ARRAY_SAMPLE_CHANNEL , RTOS_MIC_ARRAY_FORMAT_COUNT }
 

Functions

void rtos_mic_array_start (rtos_mic_array_t *mic_array_ctx, size_t buffer_size, unsigned interrupt_core_id)
 
void rtos_mic_array_init (rtos_mic_array_t *mic_array_ctx, uint32_t io_core_mask, rtos_mic_array_format_t format)
 

Detailed Description

The public API for using the RTOS mic array driver.

Typedef Documentation

◆ rtos_mic_array_t

Typedef to the RTOS mic array driver instance struct.

Enumeration Type Documentation

◆ rtos_mic_array_format_t

Typedef for the RTOS mic array driver audio format

Function Documentation

◆ rtos_mic_array_init()

void rtos_mic_array_init ( rtos_mic_array_t mic_array_ctx,
uint32_t  io_core_mask,
rtos_mic_array_format_t  format 
)

Initializes an RTOS mic array driver instance. This must only be called by the tile that owns the driver instance. It should be called before starting the RTOS, and must be called before calling rtos_mic_array_start() or any of the core mic array driver functions with this instance.

Parameters
mic_array_ctxA pointer to the mic array driver instance to initialize.
io_core_maskA bitmask representing the cores on which the low level mic array I/O thread created by the driver is allowed to run. Bit 0 is core 0, bit 1 is core 1, etc.
formatFormat of the output data

◆ rtos_mic_array_start()

void rtos_mic_array_start ( rtos_mic_array_t mic_array_ctx,
size_t  buffer_size,
unsigned  interrupt_core_id 
)

Starts an RTOS mic array driver instance. This must only be called by the tile that owns the driver instance. It must be called after starting the RTOS from an RTOS thread, and must be called before any of the core mic array driver functions are called with this instance.

rtos_mic_array_init() must be called on this mic array driver instance prior to calling this.

Parameters
mic_array_ctxA pointer to the mic array driver instance to start.
buffer_sizeThe size in frames of the input buffer. Each frame is two samples (one for each microphone) plus one sample per reference channel. This must be at least MIC_ARRAY_CONFIG_SAMPLES_PER_FRAME. Samples are pulled out of this buffer by the application by calling rtos_mic_array_rx().
interrupt_core_idThe ID of the core on which to enable the mic array interrupt.