annotate startup_stm32f10x_md_mthomas.c @ 67:dcac5f08f87a

Don't complain about CRC mismatch in flashreadblock.
author Daniel O'Connor <darius@dons.net.au>
date Sun, 14 Apr 2013 14:29:08 +0930
parents 6ad0603ea909
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
1 /**
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
2 ******************************************************************************
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
3 * @file startup_stm32f10x_md.c
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
4 * @author MCD Application Team, modified by Martin Thomas
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
5 * @version V3.0.0-mthomas4
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
6 * @date 19. Mar. 2010
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
7 * @brief STM32F10x Medium Density Devices vector table for GNU toolchain.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
8 * This module performs:
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
9 * - Set the initial SP
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
10 * - Set the initial PC == Reset_Handler,
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
11 * - Set the vector table entries with the exceptions ISR address
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
12 * - Configure the clock system
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
13 * - Branches to main in the C library (which eventually
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
14 * calls main()).
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
15 * After Reset the Cortex-M3 processor is in Thread mode,
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
16 * priority is Privileged, and the Stack is set to Main.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
17 *******************************************************************************
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
18 * @copy
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
19 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
20 * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
21 * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
22 * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
23 * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
24 * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
25 * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
26 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
27 * <h2><center>&copy; COPYRIGHT 2009 STMicroelectronics, 2010 M.Thomas</center></h2>
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
28 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
29
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
30 /* Modified by Martin Thomas
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
31 - to take VECT_TAB_RAM setting into account, also see the linker-script
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
32 - to avoid warning "ISO C forbids initialization between function pointer and 'void *'".
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
33 - added optional startup-delay to avoid unwanted operations while connecting with
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
34 debugger/programmer
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
35 - tested with the GNU arm-eabi toolchain as in CS G++ lite Q1/2009-161
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
36 - minor modification in .data copy to avoid copy while "run from RAM"
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
37 during debugging
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
38 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
39
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
40 /* Includes ------------------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
41 /* Private typedef -----------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
42 /* Private typedef -----------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
43 typedef void( *const intfunc )( void );
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
44
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
45 /* Private define ------------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
46 #define WEAK __attribute__ ((weak))
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
47
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
48 /* Private macro -------------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
49 extern unsigned long _etext;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
50 /* start address for the initialization values of the .data section.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
51 defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
52 extern unsigned long _sidata;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
53
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
54 /* start address for the .data section. defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
55 extern unsigned long _sdata;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
56
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
57 /* end address for the .data section. defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
58 extern unsigned long _edata;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
59
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
60 /* start address for the .bss section. defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
61 extern unsigned long _sbss;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
62
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
63 /* end address for the .bss section. defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
64 extern unsigned long _ebss;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
65
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
66 /* init value for the stack pointer. defined in linker script */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
67 extern unsigned long _estack;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
68
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
69 /* Private variables ---------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
70
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
71 /* Private function prototypes -----------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
72 void Reset_Handler(void) __attribute__((__interrupt__));
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
73 void __Init_Data_and_BSS(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
74 void Default_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
75
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
76 /* External function prototypes ----------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
77 extern int main(void); /* Application's main function */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
78 extern void SystemInit(void); /* STM's system init */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
79 extern void __libc_init_array(void); /* calls CTORS of static objects */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
80
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
81
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
82 /*******************************************************************************
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
83 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
84 * Forward declaration of the default fault handlers.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
85 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
86 *******************************************************************************/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
87 //mthomas void WEAK Reset_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
88 void WEAK NMI_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
89 void WEAK HardFault_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
90 void WEAK MemManage_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
91 void WEAK BusFault_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
92 void WEAK UsageFault_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
93 //mthomas void WEAK MemManage_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
94 void WEAK SVC_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
95 void WEAK DebugMon_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
96 void WEAK PendSV_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
97 void WEAK SysTick_Handler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
98
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
99 /* External Interrupts */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
100 void WEAK WWDG_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
101 void WEAK PVD_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
102 void WEAK TAMPER_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
103 void WEAK RTC_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
104 void WEAK FLASH_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
105 void WEAK RCC_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
106 void WEAK EXTI0_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
107 void WEAK EXTI1_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
108 void WEAK EXTI2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
109 void WEAK EXTI3_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
110 void WEAK EXTI4_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
111 void WEAK DMA1_Channel1_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
112 void WEAK DMA1_Channel2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
113 void WEAK DMA1_Channel3_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
114 void WEAK DMA1_Channel4_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
115 void WEAK DMA1_Channel5_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
116 void WEAK DMA1_Channel6_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
117 void WEAK DMA1_Channel7_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
118 void WEAK ADC1_2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
119 void WEAK USB_HP_CAN1_TX_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
120 void WEAK USB_LP_CAN1_RX0_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
121 void WEAK CAN1_RX1_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
122 void WEAK CAN1_SCE_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
123 void WEAK EXTI9_5_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
124 void WEAK TIM1_BRK_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
125 void WEAK TIM1_UP_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
126 void WEAK TIM1_TRG_COM_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
127 void WEAK TIM1_CC_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
128 void WEAK TIM2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
129 void WEAK TIM3_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
130 void WEAK TIM4_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
131 void WEAK I2C1_EV_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
132 void WEAK I2C1_ER_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
133 void WEAK I2C2_EV_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
134 void WEAK I2C2_ER_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
135 void WEAK SPI1_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
136 void WEAK SPI2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
137 void WEAK USART1_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
138 void WEAK USART2_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
139 void WEAK USART3_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
140 void WEAK EXTI15_10_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
141 void WEAK RTCAlarm_IRQHandler(void);
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
142 void WEAK USBWakeUp_IRQHandler(void);
53
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
143 void WEAK TIM8Brk_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
144 void WEAK TIM8Up_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
145 void WEAK TIM8_Trg_Com_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
146 void WEAK TIM8_CC_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
147 void WEAK ADC3_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
148 void WEAK FSMC_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
149 void WEAK SDIO_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
150 void WEAK TIM5_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
151 void WEAK SPI3_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
152 void WEAK UART4_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
153 void WEAK UART5_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
154 void WEAK TIM6_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
155 void WEAK TIM7_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
156 void WEAK DMA2_Channel1_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
157 void WEAK DMA2_Channel2_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
158 void WEAK DMA2_Channel3_IRQHandler(void);
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
159 void WEAK DMA2_Channel4_5_IRQHandler(void);
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
160
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
161 /* Private functions ---------------------------------------------------------*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
162 /******************************************************************************
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
163 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
164 * mthomas: If been built with VECT_TAB_RAM this creates two tables:
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
165 * (1) a minimal table (stack-pointer, reset-vector) used during startup
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
166 * before relocation of the vector table using SCB_VTOR
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
167 * (2) a full table which is copied to RAM and used after vector relocation
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
168 * (NVIC_SetVectorTable)
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
169 * If been built without VECT_TAB_RAM the following comment from STM is valid:
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
170 * The minimal vector table for a Cortex M3. Note that the proper constructs
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
171 * must be placed on this to ensure that it ends up at physical address
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
172 * 0x0000.0000.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
173 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
174 ******************************************************************************/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
175
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
176 #ifdef VECT_TAB_RAM
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
177 __attribute__ ((section(".isr_vectorsflash")))
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
178 void (* const g_pfnVectorsStartup[])(void) =
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
179 {
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
180 (intfunc)((unsigned long)&_estack), /* The initial stack pointer during startup */
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
181 Reset_Handler, /* The reset handler during startup */
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
182 HardFault_Handler, /* Hard Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
183 MemManage_Handler, /* MPU Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
184 BusFault_Handler, /* Bus Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
185 UsageFault_Handler, /* Usage Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
186 };
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
187 __attribute__ ((section(".isr_vectorsram")))
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
188 void (* g_pfnVectors[])(void) =
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
189 #else /* VECT_TAB_RAM */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
190 __attribute__ ((section(".isr_vectorsflash")))
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
191 void (* const g_pfnVectors[])(void) =
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
192 #endif /* VECT_TAB_RAM */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
193 {
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
194 (intfunc)((unsigned long)&_estack), /* The stack pointer after relocation */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
195 Reset_Handler, /* Reset Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
196 NMI_Handler, /* NMI Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
197 HardFault_Handler, /* Hard Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
198 MemManage_Handler, /* MPU Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
199 BusFault_Handler, /* Bus Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
200 UsageFault_Handler, /* Usage Fault Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
201 0, /* Reserved */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
202 0, /* Reserved */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
203 0, /* Reserved */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
204 0, /* Reserved */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
205 SVC_Handler, /* SVCall Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
206 DebugMon_Handler, /* Debug Monitor Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
207 0, /* Reserved */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
208 PendSV_Handler, /* PendSV Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
209 SysTick_Handler, /* SysTick Handler */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
210
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
211 /* External Interrupts */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
212 WWDG_IRQHandler, /* Window Watchdog */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
213 PVD_IRQHandler, /* PVD through EXTI Line detect */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
214 TAMPER_IRQHandler, /* Tamper */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
215 RTC_IRQHandler, /* RTC */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
216 FLASH_IRQHandler, /* Flash */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
217 RCC_IRQHandler, /* RCC */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
218 EXTI0_IRQHandler, /* EXTI Line 0 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
219 EXTI1_IRQHandler, /* EXTI Line 1 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
220 EXTI2_IRQHandler, /* EXTI Line 2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
221 EXTI3_IRQHandler, /* EXTI Line 3 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
222 EXTI4_IRQHandler, /* EXTI Line 4 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
223 DMA1_Channel1_IRQHandler, /* DMA1 Channel 1 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
224 DMA1_Channel2_IRQHandler, /* DMA1 Channel 2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
225 DMA1_Channel3_IRQHandler, /* DMA1 Channel 3 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
226 DMA1_Channel4_IRQHandler, /* DMA1 Channel 4 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
227 DMA1_Channel5_IRQHandler, /* DMA1 Channel 5 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
228 DMA1_Channel6_IRQHandler, /* DMA1 Channel 6 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
229 DMA1_Channel7_IRQHandler, /* DMA1 Channel 7 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
230 ADC1_2_IRQHandler, /* ADC1 & ADC2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
231 USB_HP_CAN1_TX_IRQHandler, /* USB High Priority or CAN1 TX */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
232 USB_LP_CAN1_RX0_IRQHandler, /* USB Low Priority or CAN1 RX0 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
233 CAN1_RX1_IRQHandler, /* CAN1 RX1 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
234 CAN1_SCE_IRQHandler, /* CAN1 SCE */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
235 EXTI9_5_IRQHandler, /* EXTI Line 9..5 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
236 TIM1_BRK_IRQHandler, /* TIM1 Break */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
237 TIM1_UP_IRQHandler, /* TIM1 Update */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
238 TIM1_TRG_COM_IRQHandler, /* TIM1 Trigger and Commutation */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
239 TIM1_CC_IRQHandler, /* TIM1 Capture Compare */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
240 TIM2_IRQHandler, /* TIM2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
241 TIM3_IRQHandler, /* TIM3 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
242 TIM4_IRQHandler, /* TIM4 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
243 I2C1_EV_IRQHandler, /* I2C1 Event */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
244 I2C1_ER_IRQHandler, /* I2C1 Error */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
245 I2C2_EV_IRQHandler, /* I2C2 Event */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
246 I2C2_ER_IRQHandler, /* I2C2 Error */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
247 SPI1_IRQHandler, /* SPI1 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
248 SPI2_IRQHandler, /* SPI2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
249 USART1_IRQHandler, /* USART1 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
250 USART2_IRQHandler, /* USART2 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
251 USART3_IRQHandler, /* USART3 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
252 EXTI15_10_IRQHandler, /* EXTI Line 15..10 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
253 RTCAlarm_IRQHandler, /* RTC Alarm through EXTI Line */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
254 USBWakeUp_IRQHandler, /* USB Wakeup from suspend */
53
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
255 TIM8Brk_IRQHandler, /* TIM8 break */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
256 TIM8Up_IRQHandler, /* TIM8 update */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
257 TIM8_Trg_Com_IRQHandler, /* TIM8 trigger and commutation */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
258 TIM8_CC_IRQHandler, /* TIM8 capture/compare */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
259 ADC3_IRQHandler, /* ADC3 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
260 FSMC_IRQHandler, /* FSMC */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
261 SDIO_IRQHandler, /* SDIO */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
262 TIM5_IRQHandler, /* TIM5 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
263 SPI3_IRQHandler, /* SPI3 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
264 UART4_IRQHandler, /* UART4 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
265 UART5_IRQHandler, /* UART5 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
266 TIM6_IRQHandler, /* TIM6 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
267 TIM7_IRQHandler, /* TIM7 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
268 DMA2_Channel1_IRQHandler, /* DMA2 Channel 1 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
269 DMA2_Channel2_IRQHandler, /* DMA2 Channel 2 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
270 DMA2_Channel3_IRQHandler, /* DMA2 Channel 3 */
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
271 DMA2_Channel4_5_IRQHandler, /* DMA2 Channel 4 & 5 */
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
272 };
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
273
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
274 /**
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
275 * @brief This is the code that gets called when the processor first
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
276 * starts execution following a reset event. Only the absolutely
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
277 * necessary set is performed, after which the application
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
278 * supplied main() routine is called.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
279 * @param None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
280 * @retval : None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
281 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
282
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
283 void Reset_Handler(void)
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
284 {
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
285
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
286 #ifdef STARTUP_DELAY
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
287 volatile unsigned long i;
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
288 for (i=0;i<500000;i++) { ; }
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
289 #endif
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
290
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
291 /* Initialize data and bss */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
292 __Init_Data_and_BSS();
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
293
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
294 /* Call CTORS of static objects, not needed for "pure C": */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
295 /* __libc_init_array(); */
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
296
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
297 /* Setup the microcontroller system. Initialize the Embedded Flash Interface,
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
298 initialize the PLL and update the SystemFrequency variable. */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
299 SystemInit();
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
300
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
301 /* Call the application's entry point.*/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
302 main();
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
303
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
304 while(1) {
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
305 }
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
306 }
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
307
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
308 /**
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
309 * @brief initializes data and bss sections
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
310 * @param None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
311 * @retval : None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
312 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
313
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
314 void
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
315 __Init_Data_and_BSS(void) {
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
316 unsigned long *pulSrc, *pulDest;
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
317
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
318 /* Copy the data segment initializers from flash to SRAM */
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
319 pulSrc = &_sidata;
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
320 pulDest = &_sdata;
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
321 if (pulSrc != pulDest) {
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
322 for(; pulDest < &_edata; ) {
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
323 *(pulDest++) = *(pulSrc++);
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
324 }
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
325 }
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
326 /* Zero fill the bss segment. */
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
327 for(pulDest = &_sbss; pulDest < &_ebss; ) {
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
328 *(pulDest++) = 0;
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
329 }
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
330 }
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
331
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
332 /*******************************************************************************
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
333 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
334 * Provide weak aliases for each Exception handler to the Default_Handler.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
335 * As they are weak aliases, any function with the same name will override
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
336 * this definition.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
337 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
338 *******************************************************************************/
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
339 #pragma weak MMI_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
340 #pragma weak MemManage_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
341 #pragma weak BusFault_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
342 #pragma weak UsageFault_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
343 #pragma weak SVC_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
344 #pragma weak DebugMon_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
345 #pragma weak PendSV_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
346 #pragma weak SysTick_Handler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
347 #pragma weak WWDG_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
348 #pragma weak PVD_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
349 #pragma weak TAMPER_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
350 #pragma weak RTC_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
351 #pragma weak FLASH_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
352 #pragma weak RCC_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
353 #pragma weak EXTI0_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
354 #pragma weak EXTI1_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
355 #pragma weak EXTI2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
356 #pragma weak EXTI3_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
357 #pragma weak EXTI4_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
358 #pragma weak DMA1_Channel1_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
359 #pragma weak DMA1_Channel2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
360 #pragma weak DMA1_Channel3_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
361 #pragma weak DMA1_Channel4_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
362 #pragma weak DMA1_Channel5_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
363 #pragma weak DMA1_Channel6_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
364 #pragma weak DMA1_Channel7_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
365 #pragma weak ADC1_2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
366 #pragma weak USB_HP_CAN1_TX_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
367 #pragma weak USB_LP_CAN1_RX0_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
368 #pragma weak CAN1_RX1_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
369 #pragma weak CAN1_SCE_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
370 #pragma weak EXTI9_5_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
371 #pragma weak TIM1_BRK_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
372 #pragma weak TIM1_UP_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
373 #pragma weak TIM1_TRG_COM_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
374 #pragma weak TIM1_CC_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
375 #pragma weak TIM2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
376 #pragma weak TIM3_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
377 #pragma weak TIM4_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
378 #pragma weak I2C1_EV_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
379 #pragma weak I2C1_ER_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
380 #pragma weak I2C2_EV_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
381 #pragma weak I2C2_ER_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
382 #pragma weak SPI1_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
383 #pragma weak SPI2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
384 #pragma weak USART1_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
385 #pragma weak USART2_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
386 #pragma weak USART3_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
387 #pragma weak EXTI15_10_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
388 #pragma weak RTCAlarm_IRQHandler = Default_Handler
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
389 #pragma weak USBWakeUp_IRQHandler = Default_Handler
53
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
390 #pragma weak TIM8Brk_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
391 #pragma weak TIM8Up_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
392 #pragma weak TIM8_Trg_Com_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
393 #pragma weak TIM8_CC_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
394 #pragma weak ADC3_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
395 #pragma weak FSMC_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
396 #pragma weak SDIO_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
397 #pragma weak TIM5_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
398 #pragma weak SPI3_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
399 #pragma weak UART4_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
400 #pragma weak UART5_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
401 #pragma weak TIM6_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
402 #pragma weak TIM7_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
403 #pragma weak DMA2_Channel1_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
404 #pragma weak DMA2_Channel2_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
405 #pragma weak DMA2_Channel3_IRQHandler = Default_Handler
6ad0603ea909 Add all the interrupt sources.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
406 #pragma weak DMA2_Channel4_5_IRQHandler = Default_Handler
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
407
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
408 /**
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
409 * @brief This is the code that gets called when the processor receives an
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
410 * unexpected interrupt. This simply enters an infinite loop, preserving
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
411 * the system state for examination by a debugger.
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
412 *
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
413 * @param None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
414 * @retval : None
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
415 */
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
416
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
417 void
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
418 Default_Handler(void) {
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
419 /* Go into an infinite loop. */
3
74e9b3baac1e Jumbo commit to make things work.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
420 while (1) {
0
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
421 }
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
422 }
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
423
c59513fd84fb Initial commit of STM32 test code.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
424 /******************* (C) COPYRIGHT 2009 STMicroelectronics *****END OF FILE****/