1 /* -------------------------------- Arctic Core ------------------------------
2 * Arctic Core - the open source AUTOSAR platform http://arccore.com
4 * Copyright (C) 2009 ArcCore AB <contact@arccore.com>
6 * This source code is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published by the
8 * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * -------------------------------- Arctic Core ------------------------------*/
19 #include "stm32f10x.h"
\r
21 typedef IRQn_Type IrqType;
23 /* Offset from start of exceptions to interrupts
24 * Exceptions have negative offsets while interrupts have positive
26 #define IRQ_INTERRUPT_OFFSET 16
\r
28 /* Total number of interrupts and exceptions
31 #if defined(STM32F10X_LD) || defined(STM32F10X_MD)
32 #define NUMBER_OF_INTERRUPTS_AND_EXCEPTIONS (USBWakeUp_IRQn+IRQ_INTERRUPT_OFFSET)
33 #elif defined(STM32F10X_HD)
34 #define NUMBER_OF_INTERRUPTS_AND_EXCEPTIONS (DMA2_Channel4_5_IRQn+IRQ_INTERRUPT_OFFSET)
35 #elif defined(STM32F10X_CL)
36 #define NUMBER_OF_INTERRUPTS_AND_EXCEPTIONS (OTG_FS_IRQn+IRQ_INTERRUPT_OFFSET)
38 #error No device selected