/Projects/STM32469I-Discovery/Applications/Audio/Audio_playback_and_record/Src/stm32f4xx_it.c

https://github.com/STMicroelectronics/STM32CubeF4 · C · 204 lines · 62 code · 20 blank · 122 comment · 4 complexity · 5344a8658a3943d90a75a9231245e065 MD5 · raw file

  1. /**
  2. ******************************************************************************
  3. * @file Audio/Audio_playback_and_record/Src/stm32f4xx_it.c
  4. * @author MCD Application Team
  5. * @brief Main Interrupt Service Routines.
  6. * This file provides template for all exceptions handler and
  7. * peripherals interrupt service routine.
  8. ******************************************************************************
  9. * @attention
  10. *
  11. * <h2><center>&copy; COPYRIGHT(c) 2017 STMicroelectronics</center></h2>
  12. *
  13. * Licensed under MCD-ST Liberty SW License Agreement V2, (the "License");
  14. * You may not use this file except in compliance with the License.
  15. * You may obtain a copy of the License at:
  16. *
  17. * http://www.st.com/software_license_agreement_liberty_v2
  18. *
  19. * Unless required by applicable law or agreed to in writing, software
  20. * distributed under the License is distributed on an "AS IS" BASIS,
  21. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  22. * See the License for the specific language governing permissions and
  23. * limitations under the License.
  24. *
  25. ******************************************************************************
  26. */
  27. /* Includes ------------------------------------------------------------------*/
  28. #include "main.h"
  29. #include "stm32f4xx_it.h"
  30. /* Private typedef -----------------------------------------------------------*/
  31. /* Private define ------------------------------------------------------------*/
  32. /* Private macro -------------------------------------------------------------*/
  33. /* Private variables ---------------------------------------------------------*/
  34. extern HCD_HandleTypeDef hhcd;
  35. /* SAI handler declared in "stm32469i_discovery_audio.c" file */
  36. extern SAI_HandleTypeDef haudio_out_sai;
  37. /* I2S handler declared in "stm32469i_discovery_audio.c" file */
  38. extern I2S_HandleTypeDef haudio_in_i2s;
  39. /* Private function prototypes -----------------------------------------------*/
  40. /* Private functions ---------------------------------------------------------*/
  41. /******************************************************************************/
  42. /* Cortex-M4 Processor Exceptions Handlers */
  43. /******************************************************************************/
  44. /**
  45. * @brief This function handles NMI exception.
  46. * @param None
  47. * @retval None
  48. */
  49. void NMI_Handler(void)
  50. {
  51. }
  52. /**
  53. * @brief This function handles Hard Fault exception.
  54. * @param None
  55. * @retval None
  56. */
  57. void HardFault_Handler(void)
  58. {
  59. /* Go to infinite loop when Hard Fault exception occurs */
  60. while (1)
  61. {
  62. }
  63. }
  64. /**
  65. * @brief This function handles Memory Manage exception.
  66. * @param None
  67. * @retval None
  68. */
  69. void MemManage_Handler(void)
  70. {
  71. /* Go to infinite loop when Memory Manage exception occurs */
  72. while (1)
  73. {
  74. }
  75. }
  76. /**
  77. * @brief This function handles Bus Fault exception.
  78. * @param None
  79. * @retval None
  80. */
  81. void BusFault_Handler(void)
  82. {
  83. /* Go to infinite loop when Bus Fault exception occurs */
  84. while (1)
  85. {
  86. }
  87. }
  88. /**
  89. * @brief This function handles Usage Fault exception.
  90. * @param None
  91. * @retval None
  92. */
  93. void UsageFault_Handler(void)
  94. {
  95. /* Go to infinite loop when Usage Fault exception occurs */
  96. while (1)
  97. {
  98. }
  99. }
  100. /**
  101. * @brief This function handles SVCall exception.
  102. * @param None
  103. * @retval None
  104. */
  105. void SVC_Handler(void)
  106. {
  107. }
  108. /**
  109. * @brief This function handles Debug Monitor exception.
  110. * @param None
  111. * @retval None
  112. */
  113. void DebugMon_Handler(void)
  114. {
  115. }
  116. /**
  117. * @brief This function handles PendSVC exception.
  118. * @param None
  119. * @retval None
  120. */
  121. void PendSV_Handler(void)
  122. {
  123. }
  124. /**
  125. * @brief This function handles SysTick Handler.
  126. * @param None
  127. * @retval None
  128. */
  129. void SysTick_Handler(void)
  130. {
  131. HAL_IncTick();
  132. Toggle_Leds();
  133. }
  134. /******************************************************************************/
  135. /* STM32F4xx Peripherals Interrupt Handlers */
  136. /* Add here the Interrupt Handler for the used peripheral(s) (PPP), for the */
  137. /* available peripheral interrupt handler's name please refer to the startup */
  138. /* file (startup_stm32f4xx.s). */
  139. /******************************************************************************/
  140. /**
  141. * @brief This function handles USB-On-The-Go FS/HS global interrupt request.
  142. * @param None
  143. * @retval None
  144. */
  145. void OTG_FS_IRQHandler(void)
  146. {
  147. HAL_HCD_IRQHandler(&hhcd);
  148. }
  149. /**
  150. * @brief This function handles External line 2 interrupt request.
  151. * @param None
  152. * @retval None
  153. */
  154. void EXTI2_IRQHandler(void)
  155. {
  156. HAL_GPIO_EXTI_IRQHandler(GPIO_PIN_2);
  157. }
  158. /**
  159. * @brief This function handles DMA2 Stream 5 interrupt request.
  160. * @param None
  161. * @retval None
  162. */
  163. void AUDIO_SAIx_DMAx_IRQHandler(void)
  164. {
  165. HAL_DMA_IRQHandler(haudio_out_sai.hdmatx);
  166. }
  167. /**
  168. * @brief This function handles DMA1 Stream 2 interrupt request.
  169. * @param None
  170. * @retval None
  171. */
  172. void AUDIO_I2Sx_DMAx_IRQHandler(void)
  173. {
  174. HAL_DMA_IRQHandler(haudio_in_i2s.hdmarx);
  175. }
  176. /**
  177. * @brief This function handles PPP interrupt request.
  178. * @param None
  179. * @retval None
  180. */
  181. /*void PPP_IRQHandler(void)
  182. {
  183. }*/
  184. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/