audioamp
2.0.0.0
|
Functions | |
void | audioamp_cfg_setup (audioamp_cfg_t *cfg) |
Config Object Initialization function. More... | |
AUDIOAMP_RETVAL | audioamp_init (audioamp_t *ctx, audioamp_cfg_t *cfg) |
Initialization function. More... | |
void | audioamp_generic_write (audioamp_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. More... | |
void | audioamp_generic_read (audioamp_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. More... | |
void | audioamp_power_on (audioamp_t *ctx) |
Turn on the Audio Amp click function. More... | |
void | audioamp_power_off (audioamp_t *ctx) |
Turn off the Audio Amp click function. More... | |
void | audioamp_set_volume (audioamp_t *ctx, uint8_t volume_value) |
Set mux volume function. More... | |
void | audioamp_set_volume_channel (audioamp_t *ctx, uint8_t channel, uint8_t volume_value) |
Set channel volume function. More... | |
void | audioamp_enable (audioamp_t *ctx) |
Enable amplifier function. More... | |
void | audioamp_disable (audioamp_t *ctx) |
Disable amplifier function. More... | |
void | audioamp_mute_mode (audioamp_t *ctx) |
Set mute mode function. More... | |
void | audioamp_unmute_mode (audioamp_t *ctx) |
Set unmute mode function. More... | |
void | audioamp_set_normal_operation (audioamp_t *ctx) |
Set normal opeation function. More... | |
void | audioamp_set_fault_detecton_control (audioamp_t *ctx, uint8_t input_command) |
Set fault detection control function. More... | |
void | audioamp_set_input (audioamp_t *ctx, uint8_t input_mode) |
Set input mixer mode function. More... | |
uint8_t | audioamp_check_status (audioamp_t *ctx) |
Check interrupt status function. More... | |
void audioamp_cfg_setup | ( | audioamp_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
This function initializes click configuration structure to init state.
uint8_t audioamp_check_status | ( | audioamp_t * | ctx | ) |
Check interrupt status function.
ctx | Click object. |
result |
|
Function check interrupt status by return value of INT pin of LM48100Q-Q1 chip on AudioAmp Click board.
void audioamp_disable | ( | audioamp_t * | ctx | ) |
Disable amplifier function.
ctx | Click object. |
Function disable the Audio Amp click by set POEWR_OFF bits to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_enable | ( | audioamp_t * | ctx | ) |
Enable amplifier function.
ctx | Click object. |
Function enable the Audio Amp click by set POEWR_ON bits to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_generic_read | ( | audioamp_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len | ||
) |
Generic read function.
ctx | Click object. |
reg | Register address. |
data_buf | Output data buf |
len | Number of the bytes to be read |
This function reads data from the desired register.
void audioamp_generic_write | ( | audioamp_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len | ||
) |
Generic write function.
ctx | Click object. |
reg | Register address. |
data_buf | Data buf to be written. |
len | Number of the bytes in data buf. |
This function writes data to the desired register.
AUDIOAMP_RETVAL audioamp_init | ( | audioamp_t * | ctx, |
audioamp_cfg_t * | cfg | ||
) |
Initialization function.
audioamp | Click object. |
cfg | Click configuration structure. |
This function initializes all necessary pins and peripherals used for this click.
void audioamp_mute_mode | ( | audioamp_t * | ctx | ) |
Set mute mode function.
ctx | Click object. |
Function set mute mode by claer INPUT_2 and INPUT_1 bits to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_power_off | ( | audioamp_t * | ctx | ) |
Turn off the Audio Amp click function.
ctx | Click object. |
Function turn off the Audio Amp click by set POEWR_OFF bits to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_power_on | ( | audioamp_t * | ctx | ) |
Turn on the Audio Amp click function.
ctx | Click object. |
Function turn on the Audio Amp click by set POEWR_ON and set INPUT_2 and INPUT_1 bits to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_set_fault_detecton_control | ( | audioamp_t * | ctx, |
uint8_t | input_command | ||
) |
Set fault detection control function.
ctx | Click object. |
input_command |
|
Function set fault detection control by set command to FAULT DETECTION CONTROL register of LM48100Q-Q1 chip.
void audioamp_set_input | ( | audioamp_t * | ctx, |
uint8_t | input_mode | ||
) |
Set input mixer mode function.
ctx | Click object. |
input_mode |
|
Function set input mixer mode by sets command to MODE CONTROL register of LM48100Q-Q1 chip.
void audioamp_set_normal_operation | ( | audioamp_t * | ctx | ) |
Set normal opeation function.
ctx | Click object. |
Function set mute mode by claer all bits to FAULT DETECTION CONTROL register of LM48100Q-Q1 chip.
void audioamp_set_volume | ( | audioamp_t * | ctx, |
uint8_t | volume_value | ||
) |
Set mux volume function.
ctx | Click object. |
volume_value | 8-bit value from 0 to 31 |
Function sets mux volume to LM48100Q-Q1 chip on AudioAmp Click board.
void audioamp_set_volume_channel | ( | audioamp_t * | ctx, |
uint8_t | channel, | ||
uint8_t | volume_value | ||
) |
Set channel volume function.
ctx | Click object. |
channel |
|
volume_value | 8-bit value from 0 to 31 |
Function sets volume of selected channel of LM48100Q-Q1 chip on AudioAmp Click board.
void audioamp_unmute_mode | ( | audioamp_t * | ctx | ) |
Set unmute mode function.
ctx | Click object. |
Function set unmute mode by sets INPUT_2 and INPUT_1 bits to MODE CONTROL register of LM48100Q-Q1 chip.