📄 91x_it.c
字号:
/******************** (C) COPYRIGHT 2007 STMicroelectronics ********************
* File Name : 91x_it.c
* Author : MCD Application Team
* Version : V2.0
* Date : 12/07/2007
* Description : Main Interrupt Service Routines.
* This file can be used to describe all the exceptions
* subroutines that may occur within user application.
* When an interrupt happens, the software will branch
* automatically to the corresponding routine.
* The following routines are all empty, user can write code
* for exceptions handlers and peripherals IRQ interrupts.
********************************************************************************
* THE PRESENT SOFTWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
* WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE TIME.
* AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY DIRECT,
* INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING FROM THE
* CONTENT OF SUCH SOFTWARE AND/OR THE USE MADE BY CUSTOMERS OF THE CODING
* INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
*******************************************************************************/
/* Includes ------------------------------------------------------------------*/
#include "91x_it.h"
/* Private typedef -----------------------------------------------------------*/
/* Private define ------------------------------------------------------------*/
/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
volatile unsigned long TMR0_arptimer = 0;
extern volatile unsigned char flg_arptimer;
/* Private function prototypes -----------------------------------------------*/
/* Private functions ---------------------------------------------------------*/
/*******************************************************************************
* Function Name : Undefined_Handler
* Description : This function Undefined instruction exception.
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void Undefined_Handler(void)
{
while(1)
{
/* infinite loop */
}
}
/*******************************************************************************
* Function Name : SWI_Handler
* Description : This function handles SW exception.
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void SWI_Handler(void)
{
}
/*******************************************************************************
* Function Name : Prefetch_Handler
* Description : This function handles preftetch abort exception.
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void Prefetch_Handler(void)
{
while(1)
{
/* infinite loop */
}
}
/*******************************************************************************
* Function Name : Abort_Handler
* Description : This function handles data abort exception.
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void Abort_Handler(void)
{
while(1)
{
/* infinite loop */
}
}
/*******************************************************************************
* Function Name : FIQ_Handler
* Description : This function handles FIQ exception.
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void FIQ_Handler(void)
{
/*write your handler here*/
/* ... */
}
/*******************************************************************************
* Function Name : WDG_IRQHandler
* Description : This function handles the WDG interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void WDG_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : SW_IRQHandler
* Description : This function handles the SW interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void SW_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : ARMRX_IRQHandler
* Description : This function handles the ARMRX interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void ARMRX_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : ARMTX_IRQHandler
* Description : This function handles the ARMTX interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void ARMTX_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : TIM0_IRQHandler
* Description : This function handles the TIM0 interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void TIM0_IRQHandler(void)
{
/*write your handler here*/
/* ... */
TIM_ClearFlag(TIM0, TIM_FLAG_OC1); /* clear Output Compare 1 flag*/
TIM_CounterCmd(TIM0, TIM_CLEAR); /* Reset TIM0 Counter*/
if(TMR0_arptimer>=40)
{
flg_arptimer=1;
}
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : TIM1_IRQHandler
* Description : This function handles the TIM1 interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void TIM1_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : TIM2_IRQHandler
* Description : This function handles the TIM2 interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void TIM2_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : TIM3_IRQHandler
* Description : This function handles the TIM3 interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void TIM3_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : USBHP_IRQHandler
* Description : This function handles the USBHP interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void USBHP_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : USBLP_IRQHandler
* Description : This function handles the USBLP interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void USBLP_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : SCU_IRQHandler
* Description : This function handles the SCU interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void SCU_IRQHandler(void)
{
/*write your handler here*/
/* ... */
/*write any value to VIC0 VAR*/
VIC0->VAR = 0xFF;
}
/*******************************************************************************
* Function Name : ENET_IRQHandler
* Description : This function handles the DENET interrupt request
* Input : None
* Output : None
* Return : None
*******************************************************************************/
void ENET_IRQHandler(void)
{
/*write your handler here*/
/* ... */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -