mirror of https://github.com/rusefi/emfat.git
125 lines
2.6 KiB
C
125 lines
2.6 KiB
C
/**
|
|
*****************************************************************************
|
|
**
|
|
** File : stm32f4xx_it.c
|
|
**
|
|
** Abstract : Main Interrupt Service Routines.
|
|
** This file provides template for all exceptions handler and
|
|
** peripherals interrupt service routine.
|
|
**
|
|
** Environment : Atollic TrueSTUDIO(R)
|
|
** STMicroelectronics STM32F4xx Standard Peripherals Library
|
|
**
|
|
** Distribution: The file is distributed “as is,” without any warranty
|
|
** of any kind.
|
|
**
|
|
** (c)Copyright Atollic AB.
|
|
** You may use this file as-is or modify it according to the needs of your
|
|
** project. Distribution of this file (unmodified or modified) is not
|
|
** permitted. Atollic AB permit registered Atollic TrueSTUDIO(R) users the
|
|
** rights to distribute the assembled, compiled & linked contents of this
|
|
** file as part of an application binary file, provided that it is built
|
|
** using the Atollic TrueSTUDIO(R) toolchain.
|
|
**
|
|
**
|
|
*****************************************************************************
|
|
*/
|
|
|
|
/* Includes ------------------------------------------------------------------*/
|
|
#include "Interrupts.h"
|
|
#include "usb_core.h"
|
|
#include "usbd_core.h"
|
|
|
|
extern USB_OTG_CORE_HANDLE USB_OTG_dev;
|
|
extern uint32_t USBD_OTG_ISR_Handler (USB_OTG_CORE_HANDLE *pdev);
|
|
extern void DISCOVERY_EXTI_IRQHandler(void);
|
|
|
|
/**
|
|
* @brief This function handles NMI exception.
|
|
* @param None
|
|
* @retval None
|
|
*/
|
|
void NMI_Handler(void)
|
|
{
|
|
}
|
|
|
|
void HardFault_Handler(void)
|
|
{
|
|
while (1)
|
|
{
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @brief This function handles Memory Manage exception.
|
|
* @param None
|
|
* @retval None
|
|
*/
|
|
void MemManage_Handler(void)
|
|
{
|
|
/* Go to infinite loop when Memory Manage exception occurs */
|
|
while (1)
|
|
{
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @brief This function handles Bus Fault exception.
|
|
* @param None
|
|
* @retval None
|
|
*/
|
|
void BusFault_Handler(void)
|
|
{
|
|
/* Go to infinite loop when Bus Fault exception occurs */
|
|
while (1)
|
|
{
|
|
}
|
|
}
|
|
|
|
/**
|
|
* @brief This function handles Usage Fault exception.
|
|
* @param None
|
|
* @retval None
|
|
*/
|
|
void UsageFault_Handler(void)
|
|
{
|
|
/* Go to infinite loop when Usage Fault exception occurs */
|
|
while (1)
|
|
{
|
|
}
|
|
}
|
|
|
|
void SVC_Handler(void)
|
|
{
|
|
}
|
|
|
|
void DebugMon_Handler(void)
|
|
{
|
|
}
|
|
|
|
void PendSV_Handler(void)
|
|
{
|
|
}
|
|
|
|
#ifdef USE_USB_OTG_FS
|
|
void OTG_FS_WKUP_IRQHandler(void)
|
|
{
|
|
if(USB_OTG_dev.cfg.low_power)
|
|
{
|
|
*(uint32_t *)(0xE000ED10) &= 0xFFFFFFF9 ;
|
|
SystemInit();
|
|
USB_OTG_UngateClock(&USB_OTG_dev);
|
|
}
|
|
EXTI_ClearITPendingBit(EXTI_Line18);
|
|
}
|
|
#endif
|
|
|
|
void OTG_FS_IRQHandler(void)
|
|
{
|
|
USBD_OTG_ISR_Handler(&USB_OTG_dev);
|
|
}
|
|
|
|
void EXTI0_IRQHandler(void)
|
|
{
|
|
}
|