![]() |
CI130X SDK API手册
2.2.0
本手册用于描述CI130X SDK各个组件和驱动API
|
函数 | |
int | cm_write_codec (int codec_index, void *pcm_buffer, uint32_t wait_tick) |
void | cm_get_pcm_buffer (int codec_index, uint32_t *ret_buf, uint32_t wait_ticks) |
int | cm_release_pcm_buffer (int codec_index, io_direction_t io_dir, void *pcm_buffer) |
int | cm_set_codec_mute (int codec_index, io_direction_t io_dir, int channel_flag, FunctionalState en) |
int | cm_get_codec_empty_buffer_number (int codec_index, io_direction_t io_dir) |
int | cm_get_codec_busy_buffer_number (int codec_index, io_direction_t io_dir) |
int | cm_set_codec_alc (int codec_index, cm_cha_sel_t cha, FunctionalState alc_enable) |
CODEC ADC ALC开关的接口 更多... | |
int | cm_set_codec_adc_gain (int codec_index, cm_cha_sel_t cha, int gain) |
设置ADC的gain,只开放PGA增益调节 更多... | |
void | audio_pre_rslt_write_data (int16_t *left, int16_t *right) |
写数据到发送端 更多... | |
int cm_get_codec_busy_buffer_number | ( | int | codec_index, |
io_direction_t | io_dir | ||
) |
int cm_get_codec_empty_buffer_number | ( | int | codec_index, |
io_direction_t | io_dir | ||
) |
void cm_get_pcm_buffer | ( | int | codec_index, |
uint32_t * | ret_buf, | ||
uint32_t | wait_ticks | ||
) |
int cm_release_pcm_buffer | ( | int | codec_index, |
io_direction_t | io_dir, | ||
void * | pcm_buffer | ||
) |
int cm_set_codec_adc_gain | ( | int | codec_index, |
cm_cha_sel_t | cha, | ||
int | gain | ||
) |
设置ADC的gain,只开放PGA增益调节
codec_index | |
cha | 通道 |
gain | 增益(-18dB —— 28dB) |
int cm_set_codec_alc | ( | int | codec_index, |
cm_cha_sel_t | cha, | ||
FunctionalState | alc_enable | ||
) |
CODEC ADC ALC开关的接口
codec_index | CODEC编号 |
cha | 左声道或者右声道,不可以双声道 |
alc_enable | ALC开关 |
int cm_set_codec_mute | ( | int | codec_index, |
io_direction_t | io_dir, | ||
int | channel_flag, | ||
FunctionalState | en | ||
) |
int cm_write_codec | ( | int | codec_index, |
void * | pcm_buffer, | ||
uint32_t | wait_tick | ||
) |