stm32f7xx_it.c 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. /* USER CODE BEGIN Header */
  2. /**
  3. ******************************************************************************
  4. * @file stm32f7xx_it.c
  5. * @brief Interrupt Service Routines.
  6. ******************************************************************************
  7. * @attention
  8. *
  9. * Copyright (c) 2024 STMicroelectronics.
  10. * All rights reserved.
  11. *
  12. * This software is licensed under terms that can be found in the LICENSE file
  13. * in the root directory of this software component.
  14. * If no LICENSE file comes with this software, it is provided AS-IS.
  15. *
  16. ******************************************************************************
  17. */
  18. /* USER CODE END Header */
  19. /* Includes ------------------------------------------------------------------*/
  20. #include "main.h"
  21. #include "stm32f7xx_it.h"
  22. /* Private includes ----------------------------------------------------------*/
  23. /* USER CODE BEGIN Includes */
  24. /* USER CODE END Includes */
  25. /* Private typedef -----------------------------------------------------------*/
  26. /* USER CODE BEGIN TD */
  27. /* USER CODE END TD */
  28. /* Private define ------------------------------------------------------------*/
  29. /* USER CODE BEGIN PD */
  30. /* USER CODE END PD */
  31. /* Private macro -------------------------------------------------------------*/
  32. /* USER CODE BEGIN PM */
  33. /* USER CODE END PM */
  34. /* Private variables ---------------------------------------------------------*/
  35. /* USER CODE BEGIN PV */
  36. /* USER CODE END PV */
  37. /* Private function prototypes -----------------------------------------------*/
  38. /* USER CODE BEGIN PFP */
  39. /* USER CODE END PFP */
  40. /* Private user code ---------------------------------------------------------*/
  41. /* USER CODE BEGIN 0 */
  42. /* USER CODE END 0 */
  43. /* External variables --------------------------------------------------------*/
  44. extern TIM_HandleTypeDef htim1;
  45. /* USER CODE BEGIN EV */
  46. /* USER CODE END EV */
  47. /******************************************************************************/
  48. /* Cortex-M7 Processor Interruption and Exception Handlers */
  49. /******************************************************************************/
  50. /**
  51. * @brief This function handles Non maskable interrupt.
  52. */
  53. void NMI_Handler(void)
  54. {
  55. /* USER CODE BEGIN NonMaskableInt_IRQn 0 */
  56. /* USER CODE END NonMaskableInt_IRQn 0 */
  57. /* USER CODE BEGIN NonMaskableInt_IRQn 1 */
  58. while (1)
  59. {
  60. }
  61. /* USER CODE END NonMaskableInt_IRQn 1 */
  62. }
  63. /**
  64. * @brief This function handles Hard fault interrupt.
  65. */
  66. void HardFault_Handler(void)
  67. {
  68. /* USER CODE BEGIN HardFault_IRQn 0 */
  69. /* USER CODE END HardFault_IRQn 0 */
  70. while (1)
  71. {
  72. /* USER CODE BEGIN W1_HardFault_IRQn 0 */
  73. /* USER CODE END W1_HardFault_IRQn 0 */
  74. }
  75. }
  76. /**
  77. * @brief This function handles Memory management fault.
  78. */
  79. void MemManage_Handler(void)
  80. {
  81. /* USER CODE BEGIN MemoryManagement_IRQn 0 */
  82. /* USER CODE END MemoryManagement_IRQn 0 */
  83. while (1)
  84. {
  85. /* USER CODE BEGIN W1_MemoryManagement_IRQn 0 */
  86. /* USER CODE END W1_MemoryManagement_IRQn 0 */
  87. }
  88. }
  89. /**
  90. * @brief This function handles Pre-fetch fault, memory access fault.
  91. */
  92. void BusFault_Handler(void)
  93. {
  94. /* USER CODE BEGIN BusFault_IRQn 0 */
  95. /* USER CODE END BusFault_IRQn 0 */
  96. while (1)
  97. {
  98. /* USER CODE BEGIN W1_BusFault_IRQn 0 */
  99. /* USER CODE END W1_BusFault_IRQn 0 */
  100. }
  101. }
  102. /**
  103. * @brief This function handles Undefined instruction or illegal state.
  104. */
  105. void UsageFault_Handler(void)
  106. {
  107. /* USER CODE BEGIN UsageFault_IRQn 0 */
  108. /* USER CODE END UsageFault_IRQn 0 */
  109. while (1)
  110. {
  111. /* USER CODE BEGIN W1_UsageFault_IRQn 0 */
  112. /* USER CODE END W1_UsageFault_IRQn 0 */
  113. }
  114. }
  115. /**
  116. * @brief This function handles Debug monitor.
  117. */
  118. void DebugMon_Handler(void)
  119. {
  120. /* USER CODE BEGIN DebugMonitor_IRQn 0 */
  121. /* USER CODE END DebugMonitor_IRQn 0 */
  122. /* USER CODE BEGIN DebugMonitor_IRQn 1 */
  123. /* USER CODE END DebugMonitor_IRQn 1 */
  124. }
  125. /******************************************************************************/
  126. /* STM32F7xx Peripheral Interrupt Handlers */
  127. /* Add here the Interrupt Handlers for the used peripherals. */
  128. /* For the available peripheral interrupt handler names, */
  129. /* please refer to the startup file (startup_stm32f7xx.s). */
  130. /******************************************************************************/
  131. /**
  132. * @brief This function handles TIM1 update interrupt and TIM10 global interrupt.
  133. */
  134. void TIM1_UP_TIM10_IRQHandler(void)
  135. {
  136. /* USER CODE BEGIN TIM1_UP_TIM10_IRQn 0 */
  137. /* USER CODE END TIM1_UP_TIM10_IRQn 0 */
  138. HAL_TIM_IRQHandler(&htim1);
  139. /* USER CODE BEGIN TIM1_UP_TIM10_IRQn 1 */
  140. /* USER CODE END TIM1_UP_TIM10_IRQn 1 */
  141. }
  142. /* USER CODE BEGIN 1 */
  143. /* USER CODE END 1 */