Select one of the symbols to view example projects that use it.
 
Outline
Includes
#include "audio_if.h"
External variables
AudioIf
haudio
AUDIO_IF_RegisterCallbacks(pFunc, pFunc, pFunc)
BSP_AUDIO_OUT_TransferComplete_CallBack()
BSP_AUDIO_OUT_HalfTransfer_CallBack()
BSP_AUDIO_OUT_Error_CallBack()
Files
loading...
CodeScopeSTM32 Libraries and SamplesSTemWinModules/Common/audio_if.c
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
/** ****************************************************************************** * @file audio_if.c * @author MCD Application Team * @brief Audio common interface ****************************************************************************** * @attention * * Copyright (c) 2017 STMicroelectronics. * All rights reserved. * * This software is licensed under terms that can be found in the LICENSE file * in the root directory of this software component. * If no LICENSE file comes with this software, it is provided AS-IS. * ****************************************************************************** *//* ... */ /* Includes ------------------------------------------------------------------*/ #include "audio_if.h" /** @addtogroup AUDIO_PLAYER_MODULE * @{ *//* ... */ /** @defgroup AUDIO_APPLICATION * @brief audio application routines * @{ *//* ... */ Includes /* External variables --------------------------------------------------------*/ static AUDIO_IFTypeDef AudioIf; AUDIO_ProcessTypdef haudio; External variables /* Private typedef -----------------------------------------------------------*/ /* Private defines -----------------------------------------------------------*/ /* Private macros ------------------------------------------------------------*/ /* Private variables ---------------------------------------------------------*/ /* Private function prototypes -----------------------------------------------*/ /* Private functions ---------------------------------------------------------*/ /** * @brief Register Audio callbacks * @param callbacks * @retval None *//* ... */ void AUDIO_IF_RegisterCallbacks(pFunc tc_cb, pFunc ht_cb, pFunc err_cb) { AudioIf.TransferComplete_CallBack = tc_cb; AudioIf.HalfTransfer_CallBack = ht_cb; AudioIf.Error_CallBack = err_cb; }{ ... } /** * @brief Manages the DMA Transfer complete interrupt. * @param None * @retval None *//* ... */ void BSP_AUDIO_OUT_TransferComplete_CallBack(void) { if(AudioIf.TransferComplete_CallBack) { AudioIf.TransferComplete_CallBack(); }if (AudioIf.TransferComplete_CallBack) { ... } }{ ... } /** * @brief Manages the DMA Half Transfer complete interrupt. * @param None * @retval None *//* ... */ void BSP_AUDIO_OUT_HalfTransfer_CallBack(void) { if (AudioIf.HalfTransfer_CallBack ) { AudioIf.HalfTransfer_CallBack(); }if (AudioIf.HalfTransfer_CallBack) { ... } }{ ... } /** * @brief Manages the DMA FIFO error interrupt. * @param None * @retval None *//* ... */ void BSP_AUDIO_OUT_Error_CallBack(void) { if(AudioIf.Error_CallBack) { AudioIf.Error_CallBack(); }if (AudioIf.Error_CallBack) { ... } }{ ... }