STM32L152D_EVAL BSP User Manual
|
Functions | |
uint8_t | BSP_AUDIO_IN_Init (uint32_t AudioFreq, uint32_t BitRes, uint32_t ChnlNbr) |
Initialize wave recording. | |
uint8_t | BSP_AUDIO_IN_Record (uint16_t *pData, uint32_t Size) |
Start audio recording. | |
uint8_t | BSP_AUDIO_IN_Stop (void) |
Stop audio recording. | |
uint8_t | BSP_AUDIO_IN_Pause (void) |
This function Pauses the audio file stream. | |
uint8_t | BSP_AUDIO_IN_Resume (void) |
This function Resumes the audio file stream. | |
uint8_t | BSP_AUDIO_IN_SetVolume (uint8_t Volume) |
Controls the audio in volume level. | |
void | BSP_AUDIO_IN_TransferComplete_CallBack (void) |
User callback when record buffer is filled. | |
void | BSP_AUDIO_IN_HalfTransfer_CallBack (void) |
Manages the DMA Half Transfer complete event. | |
void | BSP_AUDIO_IN_Error_Callback (void) |
Audio IN Error callback function. |
Function Documentation
void BSP_AUDIO_IN_Error_Callback | ( | void | ) |
Audio IN Error callback function.
- Return values:
-
None
Definition at line 709 of file stm32l152d_eval_audio.c.
void BSP_AUDIO_IN_HalfTransfer_CallBack | ( | void | ) |
Manages the DMA Half Transfer complete event.
- Return values:
-
None
Definition at line 698 of file stm32l152d_eval_audio.c.
Referenced by HAL_ADC_ConvHalfCpltCallback().
uint8_t BSP_AUDIO_IN_Init | ( | uint32_t | AudioFreq, |
uint32_t | BitRes, | ||
uint32_t | ChnlNbr | ||
) |
Initialize wave recording.
- Parameters:
-
AudioFreq Audio frequency acquisition. Note: On STM32L1 evaluation board, the microphone acquisition is done through an analong amplifier with a band-pass filter centered at 32kHz. Therefore, this parameter value should be set at maximum to 32kHz (value "32000"). BitRes Audio frequency to be configured for the I2S peripheral. Note: On STM32L1 evaluation board, this parameter is not used, but kept as parameter for compatibility with other STM32 BSP drivers. ChnlNbr Audio frequency to be configured for the I2S peripheral. Note: On STM32L1 evaluation board, this parameter is not used, but kept as parameter for compatibility with other STM32 BSP drivers.
- Return values:
-
AUDIO_OK if correct communication, else wrong communication
Definition at line 478 of file stm32l152d_eval_audio.c.
References ADCx_MspInit(), AUDIO_ERROR, AUDIO_IN_ADC_CHANNEL, AUDIO_OK, hAudioInAdc, hAudioInConfigAdc, hAudioInOpamp, hAudioInTim3, OPAMPx_MspInit(), and TIMx_Base_MspInit().
uint8_t BSP_AUDIO_IN_Pause | ( | void | ) |
This function Pauses the audio file stream.
- Return values:
-
AUDIO_OK if correct communication, else wrong communication
Definition at line 637 of file stm32l152d_eval_audio.c.
References AUDIO_ERROR, AUDIO_OK, and hAudioInTim3.
uint8_t BSP_AUDIO_IN_Record | ( | uint16_t * | pbuf, |
uint32_t | size | ||
) |
Start audio recording.
- Parameters:
-
pbuf Main buffer pointer for the recorded data storing size Current size of the recorded buffer
- Return values:
-
AUDIO_OK if correct communication, else wrong communication
Definition at line 578 of file stm32l152d_eval_audio.c.
References AUDIO_ERROR, AUDIO_OK, hAudioInAdc, and hAudioInTim3.
uint8_t BSP_AUDIO_IN_Resume | ( | void | ) |
This function Resumes the audio file stream.
- Return values:
-
AUDIO_OK if correct communication, else wrong communication
Definition at line 655 of file stm32l152d_eval_audio.c.
References AUDIO_ERROR, AUDIO_OK, and hAudioInTim3.
uint8_t BSP_AUDIO_IN_SetVolume | ( | uint8_t | Volume | ) |
Controls the audio in volume level.
- Parameters:
-
Volume,: Volume level to be set in percentage from 0% to 100% (0 for Mute and 100 for Max volume level).
- Return values:
-
AUDIO_OK if correct communication, else wrong communication
Definition at line 675 of file stm32l152d_eval_audio.c.
References AUDIO_OK, and AudioInVolume.
uint8_t BSP_AUDIO_IN_Stop | ( | void | ) |
Stop audio recording.
- Return values:
-
None
Definition at line 608 of file stm32l152d_eval_audio.c.
References AUDIO_ERROR, AUDIO_OK, hAudioInAdc, hAudioInOpamp, and hAudioInTim3.
void BSP_AUDIO_IN_TransferComplete_CallBack | ( | void | ) |
User callback when record buffer is filled.
- Return values:
-
None
Definition at line 687 of file stm32l152d_eval_audio.c.
Referenced by HAL_ADC_ConvCpltCallback().
Generated on Thu Aug 24 2017 17:57:48 for STM32L152D_EVAL BSP User Manual by
