PageRenderTime 28ms CodeModel.GetById 28ms RepoModel.GetById 0ms app.codeStats 0ms

/taxi_v1.2/Project/Examples/EXTI/stm32f10x_it.c

https://github.com/jiesse/time-meter
C | 188 lines | 49 code | 22 blank | 117 comment | 6 complexity | d90f9780088e529ab1fd7435dd09e97c MD5 | raw file
  1. /**
  2. ******************************************************************************
  3. * @file EXTI/stm32f10x_it.c
  4. * @author MCD Application Team
  5. * @version V3.0.0
  6. * @date 04/06/2009
  7. * @brief Main Interrupt Service Routines.
  8. * This file provides template for all exceptions handler and
  9. * peripherals interrupt service routine.
  10. ******************************************************************************
  11. * @copy
  12. *
  13. * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
  14. * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
  15. * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
  16. * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
  17. * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
  18. * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
  19. *
  20. * <h2><center>&copy; COPYRIGHT 2009 STMicroelectronics</center></h2>
  21. */
  22. /* Includes ------------------------------------------------------------------*/
  23. #include "stm32f10x_it.h"
  24. #include "platform_config.h"
  25. /** @addtogroup StdPeriph_Examples
  26. * @{
  27. */
  28. /** @addtogroup EXTI_Example
  29. * @{
  30. */
  31. /* Private typedef -----------------------------------------------------------*/
  32. /* Private define ------------------------------------------------------------*/
  33. /* Private macro -------------------------------------------------------------*/
  34. /* Private variables ---------------------------------------------------------*/
  35. /* Private function prototypes -----------------------------------------------*/
  36. /* Private functions ---------------------------------------------------------*/
  37. /******************************************************************************/
  38. /* Cortex-M3 Processor Exceptions Handlers */
  39. /******************************************************************************/
  40. /**
  41. * @brief This function handles NMI exception.
  42. * @param None
  43. * @retval : None
  44. */
  45. void NMI_Handler(void)
  46. {
  47. }
  48. /**
  49. * @brief This function handles Hard Fault exception.
  50. * @param None
  51. * @retval : None
  52. */
  53. void HardFault_Handler(void)
  54. {
  55. /* Go to infinite loop when Hard Fault exception occurs */
  56. while (1)
  57. {
  58. }
  59. }
  60. /**
  61. * @brief This function handles Memory Manage exception.
  62. * @param None
  63. * @retval : None
  64. */
  65. void MemManage_Handler(void)
  66. {
  67. /* Go to infinite loop when Memory Manage exception occurs */
  68. while (1)
  69. {
  70. }
  71. }
  72. /**
  73. * @brief This function handles Bus Fault exception.
  74. * @param None
  75. * @retval : None
  76. */
  77. void BusFault_Handler(void)
  78. {
  79. /* Go to infinite loop when Bus Fault exception occurs */
  80. while (1)
  81. {
  82. }
  83. }
  84. /**
  85. * @brief This function handles Usage Fault exception.
  86. * @param None
  87. * @retval : None
  88. */
  89. void UsageFault_Handler(void)
  90. {
  91. /* Go to infinite loop when Usage Fault exception occurs */
  92. while (1)
  93. {
  94. }
  95. }
  96. /**
  97. * @brief This function handles SVCall exception.
  98. * @param None
  99. * @retval : None
  100. */
  101. void SVC_Handler(void)
  102. {
  103. }
  104. /**
  105. * @brief This function handles Debug Monitor exception.
  106. * @param None
  107. * @retval : None
  108. */
  109. void DebugMon_Handler(void)
  110. {
  111. }
  112. /**
  113. * @brief This function handles PendSV_Handler exception.
  114. * @param None
  115. * @retval : None
  116. */
  117. void PendSV_Handler(void)
  118. {
  119. }
  120. /**
  121. * @brief This function handles SysTick Handler.
  122. * @param None
  123. * @retval : None
  124. */
  125. void SysTick_Handler(void)
  126. {
  127. }
  128. /******************************************************************************/
  129. /* STM32F10x Peripherals Interrupt Handlers */
  130. /******************************************************************************/
  131. /**
  132. * @brief This function handles External lines 9 to 5 interrupt request.
  133. * @param None
  134. * @retval : None
  135. */
  136. void EXTI9_5_IRQHandler(void)
  137. {
  138. if(EXTI_GetITStatus(EXTI_LINE_KEY_BUTTON) != RESET)
  139. {
  140. /* Toggle GPIO_LED pin 6 */
  141. GPIO_WriteBit(GPIO_LED, GPIO_Pin_6, (BitAction)((1-GPIO_ReadOutputDataBit(GPIO_LED, GPIO_Pin_6))));
  142. /* Clear the Key Button EXTI line pending bit */
  143. EXTI_ClearITPendingBit(EXTI_LINE_KEY_BUTTON);
  144. }
  145. }
  146. /******************************************************************************/
  147. /* STM32F10x Peripherals Interrupt Handlers */
  148. /* Add here the Interrupt Handler for the used peripheral(s) (PPP), for the */
  149. /* available peripheral interrupt handler's name please refer to the startup */
  150. /* file (startup_stm32f10x_xx.s). */
  151. /******************************************************************************/
  152. /**
  153. * @brief This function handles PPP interrupt request.
  154. * @param None
  155. * @retval : None
  156. */
  157. /*void PPP_IRQHandler(void)
  158. {
  159. }*/
  160. /**
  161. * @}
  162. */
  163. /**
  164. * @}
  165. */
  166. /******************* (C) COPYRIGHT 2009 STMicroelectronics *****END OF FILE****/