STM32L4R9I_EVAL BSP User Manual: Private Functions

STM32L4R9I_EVAL BSP

STM32L4R9I_EVAL BSP User Manual
Private Functions

Functions

static void AUDIO_CODEC_Reset (void)
 Resets the audio codec.
static uint8_t AUDIO_SAIx_Init (uint32_t AudioFreq, uint16_t OutputDevice)
 Initializes the Audio Codec audio interface (SAI).
static uint8_t AUDIO_SAIx_DeInit (void)
 De-initializes the Audio Codec audio interface (SAI).
static uint8_t AUDIO_DFSDMx_Init (uint32_t AudioFreq)
 Initializes the Digital Filter for Sigma-Delta Modulators interface (DFSDM).
static uint8_t AUDIO_DFSDMx_DeInit (void)
 De-initializes the Digital Filter for Sigma-Delta Modulators interface (DFSDM).
static uint8_t AUDIO_SAIPLLConfig (uint32_t Frequency)
 Configures the SAI PLL clock according to the required audio frequency.
void HAL_SAI_MspInit (SAI_HandleTypeDef *hsai)
 SAI MSP Init.
void HAL_SAI_MspDeInit (SAI_HandleTypeDef *hsai)
 SAI MSP De-init.
void HAL_DFSDM_ChannelMspInit (DFSDM_Channel_HandleTypeDef *hdfsdm_channel)
 Initializes the DFSDM channel MSP.
void HAL_DFSDM_ChannelMspDeInit (DFSDM_Channel_HandleTypeDef *hdfsdm_channel)
 DeInitializes the DFSDM channel MSP.
void HAL_DFSDM_FilterMspInit (DFSDM_Filter_HandleTypeDef *hdfsdm_filter)
 Initializes the DFSDM filter MSP.
void HAL_DFSDM_FilterMspDeInit (DFSDM_Filter_HandleTypeDef *hdfsdm_filter)
 DeInitializes the DFSDM filter MSP.

Function Documentation

static void AUDIO_CODEC_Reset ( void  ) [static]

Resets the audio codec.

It restores the default configuration of the codec (this function shall be called before initializing the codec).

Return values:
None

Definition at line 1275 of file stm32l4r9i_eval_audio.c.

References AUDIO_I2C_ADDRESS, and AUDIO_OUT_TypeDef::AudioDrv.

Referenced by BSP_AUDIO_OUT_Init().

static uint8_t AUDIO_DFSDMx_DeInit ( void  ) [static]

De-initializes the Digital Filter for Sigma-Delta Modulators interface (DFSDM).

Return values:
AUDIO_OKif correct communication, else wrong communication

Definition at line 1402 of file stm32l4r9i_eval_audio.c.

References AUDIO_ERROR, AUDIO_OK, BSP_AUDIO_hDfsdmLeftFilter, BSP_AUDIO_hDfsdmRightFilter, AUDIO_IN_TypeDef::hDfsdmLeftChannel, and AUDIO_IN_TypeDef::hDfsdmRightChannel.

Referenced by BSP_AUDIO_IN_DeInit(), and BSP_AUDIO_IN_SetFrequency().

static uint8_t AUDIO_DFSDMx_Init ( uint32_t  AudioFreq) [static]

Initializes the Digital Filter for Sigma-Delta Modulators interface (DFSDM).

Parameters:
AudioFreq,:Audio frequency to be used to set correctly the DFSDM peripheral.
Return values:
AUDIO_OKif correct communication, else wrong communication

Definition at line 1299 of file stm32l4r9i_eval_audio.c.

References AUDIO_DFSDMx_LEFT_CHANNEL, AUDIO_DFSDMx_LEFT_FILTER, AUDIO_DFSDMx_RIGHT_CHANNEL, AUDIO_DFSDMx_RIGHT_FILTER, AUDIO_ERROR, AUDIO_OK, BSP_AUDIO_hDfsdmLeftFilter, BSP_AUDIO_hDfsdmRightFilter, DFSDMClockDivider, DFSDMFilterOrder, DFSDMOverSampling, DFSDMRightBitShift, AUDIO_IN_TypeDef::hDfsdmLeftChannel, and AUDIO_IN_TypeDef::hDfsdmRightChannel.

Referenced by BSP_AUDIO_IN_Init(), and BSP_AUDIO_IN_SetFrequency().

static uint8_t AUDIO_SAIPLLConfig ( uint32_t  Frequency) [static]

Configures the SAI PLL clock according to the required audio frequency.

Parameters:
Frequency,:Audio frequency.
Return values:
BSPAUDIO status
Note:
The SAI PLL input clock must be configured in the user application. The SAI PLL configuration done within this function assumes that the SAI PLL input clock runs at 4 MHz.

Definition at line 1583 of file stm32l4r9i_eval_audio.c.

References AUDIO_ERROR, and AUDIO_OK.

Referenced by BSP_AUDIO_IN_Init(), BSP_AUDIO_IN_SetFrequency(), BSP_AUDIO_OUT_Init(), and BSP_AUDIO_OUT_SetFrequency().

static uint8_t AUDIO_SAIx_DeInit ( void  ) [static]

De-initializes the Audio Codec audio interface (SAI).

Return values:
BSPAUDIO status

Definition at line 1152 of file stm32l4r9i_eval_audio.c.

References AUDIO_ERROR, AUDIO_OK, AUDIO_SAIx_PLL_DISABLE, and BSP_AUDIO_hSai.

Referenced by BSP_AUDIO_OUT_DeInit().

static uint8_t AUDIO_SAIx_Init ( uint32_t  AudioFreq,
uint16_t  OutputDevice 
) [static]

Initializes the Audio Codec audio interface (SAI).

Parameters:
AudioFreq,:Audio frequency to be configured for the SAI peripheral.
OutputDevice,:OUTPUT_DEVICE_SPEAKER, OUTPUT_DEVICE_HEADPHONE, or OUTPUT_DEVICE_BOTH.
Note:
The default SlotActive configuration is set to CODEC_AUDIOFRAME_SLOT_0123 and user can update this configuration using
Return values:
None

Definition at line 1074 of file stm32l4r9i_eval_audio.c.

References AUDIO_ERROR, AUDIO_OK, AUDIO_SAIx, BSP_AUDIO_hSai, and SAIClockDivider.

Referenced by BSP_AUDIO_OUT_Init().

void HAL_DFSDM_ChannelMspDeInit ( DFSDM_Channel_HandleTypeDef *  hdfsdm_channel)

DeInitializes the DFSDM channel MSP.

Parameters:
hdfsdm_channel: DFSDM channel handle.
Return values:
None

Definition at line 1463 of file stm32l4r9i_eval_audio.c.

References AUDIO_DFSDMx_CKOUT_CLK_DISABLE, AUDIO_DFSDMx_CKOUT_GPIO_PORT, AUDIO_DFSDMx_CKOUT_PIN, AUDIO_DFSDMx_CLK_DISABLE, AUDIO_DFSDMx_DATIN_GPIO_PORT, and AUDIO_DFSDMx_DATIN_PIN.

void HAL_DFSDM_ChannelMspInit ( DFSDM_Channel_HandleTypeDef *  hdfsdm_channel)

Initializes the DFSDM channel MSP.

Parameters:
hdfsdm_channel: DFSDM channel handle.
Return values:
None

Definition at line 1436 of file stm32l4r9i_eval_audio.c.

References AUDIO_DFSDMx_CKOUT_CLK_ENABLE, AUDIO_DFSDMx_CKOUT_DATIN_AF, AUDIO_DFSDMx_CKOUT_GPIO_PORT, AUDIO_DFSDMx_CKOUT_PIN, AUDIO_DFSDMx_CLK_ENABLE, AUDIO_DFSDMx_DATIN_CLK_ENABLE, AUDIO_DFSDMx_DATIN_GPIO_PORT, and AUDIO_DFSDMx_DATIN_PIN.

void HAL_DFSDM_FilterMspDeInit ( DFSDM_Filter_HandleTypeDef *  hdfsdm_filter)

DeInitializes the DFSDM filter MSP.

Parameters:
hdfsdm_filter: DFSDM filter handle.
Return values:
None

Definition at line 1549 of file stm32l4r9i_eval_audio.c.

References AUDIO_DFSDMx_DMAx_CLK_DISABLE, AUDIO_DFSDMx_DMAx_LEFT_IRQ, AUDIO_DFSDMx_DMAx_RIGHT_IRQ, AUDIO_DFSDMx_LEFT_FILTER, AUDIO_IN_TypeDef::hDmaDfsdmLeft, and AUDIO_IN_TypeDef::hDmaDfsdmRight.

Generated on Thu Oct 12 2017 10:54:00 for STM32L4R9I_EVAL BSP User Manual by   doxygen 1.7.6.1