Details | Last modification | View Log | RSS feed
| Rev | Author | Line No. | Line |
|---|---|---|---|
| 2 | mjames | 1 | ;******************************************************************************* |
| 2 | ;* File Name : startup_stm32f091xc.s |
||
| 3 | ;* Author : MCD Application Team |
||
| 4 | ;* Description : STM32F091xc/STM32F098xc devices vector table for EWARM toolchain. |
||
| 5 | ;* This module performs: |
||
| 6 | ;* - Set the initial SP |
||
| 7 | ;* - Set the initial PC == __iar_program_start, |
||
| 8 | ;* - Set the vector table entries with the exceptions ISR |
||
| 9 | ;* address, |
||
| 10 | ;* - Branches to main in the C library (which eventually |
||
| 11 | ;* calls main()). |
||
| 12 | ;* After Reset the Cortex-M0 processor is in Thread mode, |
||
| 13 | ;* priority is Privileged, and the Stack is set to Main. |
||
| 14 | ;******************************************************************************* |
||
| 15 | ;* @attention |
||
| 16 | ;* |
||
| 17 | ;* <h2><center>© Copyright (c) 2016 STMicroelectronics. |
||
| 18 | ;* All rights reserved.</center></h2> |
||
| 19 | ;* |
||
| 20 | ;* This software component is licensed by ST under BSD 3-Clause license, |
||
| 21 | ;* the "License"; You may not use this file except in compliance with the |
||
| 22 | ;* License. You may obtain a copy of the License at: |
||
| 23 | ;* opensource.org/licenses/BSD-3-Clause |
||
| 24 | ;* |
||
| 25 | ;******************************************************************************* |
||
| 26 | ; |
||
| 27 | ; |
||
| 28 | ; The modules in this file are included in the libraries, and may be replaced |
||
| 29 | ; by any user-defined modules that define the PUBLIC symbol _program_start or |
||
| 30 | ; a user defined start symbol. |
||
| 31 | ; To override the cstartup defined in the library, simply add your modified |
||
| 32 | ; version to the workbench project. |
||
| 33 | ; |
||
| 34 | ; The vector table is normally located at address 0. |
||
| 35 | ; When debugging in RAM, it can be located in RAM, aligned to at least 2^6. |
||
| 36 | ; The name "__vector_table" has special meaning for C-SPY: |
||
| 37 | ; it is where the SP start value is found, and the NVIC vector |
||
| 38 | ; table register (VTOR) is initialized to this address if != 0. |
||
| 39 | ; |
||
| 40 | ; Cortex-M version |
||
| 41 | ; |
||
| 42 | |||
| 43 | MODULE ?cstartup |
||
| 44 | |||
| 45 | ;; Forward declaration of sections. |
||
| 46 | SECTION CSTACK:DATA:NOROOT(3) |
||
| 47 | |||
| 48 | SECTION .intvec:CODE:NOROOT(2) |
||
| 49 | |||
| 50 | EXTERN __iar_program_start |
||
| 51 | EXTERN SystemInit |
||
| 52 | PUBLIC __vector_table |
||
| 53 | |||
| 54 | DATA |
||
| 55 | __vector_table |
||
| 56 | DCD sfe(CSTACK) |
||
| 57 | DCD Reset_Handler ; Reset Handler |
||
| 58 | |||
| 59 | DCD NMI_Handler ; NMI Handler |
||
| 60 | DCD HardFault_Handler ; Hard Fault Handler |
||
| 61 | DCD 0 ; Reserved |
||
| 62 | DCD 0 ; Reserved |
||
| 63 | DCD 0 ; Reserved |
||
| 64 | DCD 0 ; Reserved |
||
| 65 | DCD 0 ; Reserved |
||
| 66 | DCD 0 ; Reserved |
||
| 67 | DCD 0 ; Reserved |
||
| 68 | DCD SVC_Handler ; SVCall Handler |
||
| 69 | DCD 0 ; Reserved |
||
| 70 | DCD 0 ; Reserved |
||
| 71 | DCD PendSV_Handler ; PendSV Handler |
||
| 72 | DCD SysTick_Handler ; SysTick Handler |
||
| 73 | |||
| 74 | ; External Interrupts |
||
| 75 | DCD WWDG_IRQHandler ; Window Watchdog |
||
| 76 | DCD PVD_VDDIO2_IRQHandler ; PVD and VDDIO2 through EXTI Line detect |
||
| 77 | DCD RTC_IRQHandler ; RTC through EXTI Line |
||
| 78 | DCD FLASH_IRQHandler ; FLASH |
||
| 79 | DCD RCC_CRS_IRQHandler ; RCC and CRS |
||
| 80 | DCD EXTI0_1_IRQHandler ; EXTI Line 0 and 1 |
||
| 81 | DCD EXTI2_3_IRQHandler ; EXTI Line 2 and 3 |
||
| 82 | DCD EXTI4_15_IRQHandler ; EXTI Line 4 to 15 |
||
| 83 | DCD TSC_IRQHandler ; TS |
||
| 84 | DCD DMA1_Ch1_IRQHandler ; DMA1 Channel 1 |
||
| 85 | DCD DMA1_Ch2_3_DMA2_Ch1_2_IRQHandler ; DMA1 Channel 2 and 3 & DMA2 Channel 1 and 2 |
||
| 86 | DCD DMA1_Ch4_7_DMA2_Ch3_5_IRQHandler ; DMA1 Channel 4 to 7 & DMA2 Channel 3 to 5 |
||
| 87 | DCD ADC1_COMP_IRQHandler ; ADC1, COMP1 and COMP2 |
||
| 88 | DCD TIM1_BRK_UP_TRG_COM_IRQHandler ; TIM1 Break, Update, Trigger and Commutation |
||
| 89 | DCD TIM1_CC_IRQHandler ; TIM1 Capture Compare |
||
| 90 | DCD TIM2_IRQHandler ; TIM2 |
||
| 91 | DCD TIM3_IRQHandler ; TIM3 |
||
| 92 | DCD TIM6_DAC_IRQHandler ; TIM6 and DAC |
||
| 93 | DCD TIM7_IRQHandler ; TIM7 |
||
| 94 | DCD TIM14_IRQHandler ; TIM14 |
||
| 95 | DCD TIM15_IRQHandler ; TIM15 |
||
| 96 | DCD TIM16_IRQHandler ; TIM16 |
||
| 97 | DCD TIM17_IRQHandler ; TIM17 |
||
| 98 | DCD I2C1_IRQHandler ; I2C1 |
||
| 99 | DCD I2C2_IRQHandler ; I2C2 |
||
| 100 | DCD SPI1_IRQHandler ; SPI1 |
||
| 101 | DCD SPI2_IRQHandler ; SPI2 |
||
| 102 | DCD USART1_IRQHandler ; USART1 |
||
| 103 | DCD USART2_IRQHandler ; USART2 |
||
| 104 | DCD USART3_8_IRQHandler ; USART3, USART4, USART5, USART6, USART7, USART8 |
||
| 105 | DCD CEC_CAN_IRQHandler ; CEC and CAN |
||
| 106 | |||
| 107 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
||
| 108 | ;; |
||
| 109 | ;; Default interrupt handlers. |
||
| 110 | ;; |
||
| 111 | THUMB |
||
| 112 | |||
| 113 | PUBWEAK Reset_Handler |
||
| 114 | SECTION .text:CODE:NOROOT:REORDER(2) |
||
| 115 | Reset_Handler |
||
| 116 | LDR R0, =SystemInit |
||
| 117 | BLX R0 |
||
| 118 | LDR R0, =__iar_program_start |
||
| 119 | BX R0 |
||
| 120 | |||
| 121 | PUBWEAK NMI_Handler |
||
| 122 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 123 | NMI_Handler |
||
| 124 | B NMI_Handler |
||
| 125 | |||
| 126 | PUBWEAK HardFault_Handler |
||
| 127 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 128 | HardFault_Handler |
||
| 129 | B HardFault_Handler |
||
| 130 | |||
| 131 | PUBWEAK SVC_Handler |
||
| 132 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 133 | SVC_Handler |
||
| 134 | B SVC_Handler |
||
| 135 | |||
| 136 | PUBWEAK PendSV_Handler |
||
| 137 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 138 | PendSV_Handler |
||
| 139 | B PendSV_Handler |
||
| 140 | |||
| 141 | PUBWEAK SysTick_Handler |
||
| 142 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 143 | SysTick_Handler |
||
| 144 | B SysTick_Handler |
||
| 145 | |||
| 146 | PUBWEAK WWDG_IRQHandler |
||
| 147 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 148 | WWDG_IRQHandler |
||
| 149 | B WWDG_IRQHandler |
||
| 150 | |||
| 151 | PUBWEAK PVD_VDDIO2_IRQHandler |
||
| 152 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 153 | PVD_VDDIO2_IRQHandler |
||
| 154 | B PVD_VDDIO2_IRQHandler |
||
| 155 | |||
| 156 | PUBWEAK RTC_IRQHandler |
||
| 157 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 158 | RTC_IRQHandler |
||
| 159 | B RTC_IRQHandler |
||
| 160 | |||
| 161 | PUBWEAK FLASH_IRQHandler |
||
| 162 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 163 | FLASH_IRQHandler |
||
| 164 | B FLASH_IRQHandler |
||
| 165 | |||
| 166 | PUBWEAK RCC_CRS_IRQHandler |
||
| 167 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 168 | RCC_CRS_IRQHandler |
||
| 169 | B RCC_CRS_IRQHandler |
||
| 170 | |||
| 171 | PUBWEAK EXTI0_1_IRQHandler |
||
| 172 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 173 | EXTI0_1_IRQHandler |
||
| 174 | B EXTI0_1_IRQHandler |
||
| 175 | |||
| 176 | PUBWEAK EXTI2_3_IRQHandler |
||
| 177 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 178 | EXTI2_3_IRQHandler |
||
| 179 | B EXTI2_3_IRQHandler |
||
| 180 | |||
| 181 | PUBWEAK EXTI4_15_IRQHandler |
||
| 182 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 183 | EXTI4_15_IRQHandler |
||
| 184 | B EXTI4_15_IRQHandler |
||
| 185 | |||
| 186 | PUBWEAK TSC_IRQHandler |
||
| 187 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 188 | TSC_IRQHandler |
||
| 189 | B TSC_IRQHandler |
||
| 190 | |||
| 191 | PUBWEAK DMA1_Ch1_IRQHandler |
||
| 192 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 193 | DMA1_Ch1_IRQHandler |
||
| 194 | B DMA1_Ch1_IRQHandler |
||
| 195 | |||
| 196 | PUBWEAK DMA1_Ch2_3_DMA2_Ch1_2_IRQHandler |
||
| 197 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 198 | DMA1_Ch2_3_DMA2_Ch1_2_IRQHandler |
||
| 199 | B DMA1_Ch2_3_DMA2_Ch1_2_IRQHandler |
||
| 200 | |||
| 201 | PUBWEAK DMA1_Ch4_7_DMA2_Ch3_5_IRQHandler |
||
| 202 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 203 | DMA1_Ch4_7_DMA2_Ch3_5_IRQHandler |
||
| 204 | B DMA1_Ch4_7_DMA2_Ch3_5_IRQHandler |
||
| 205 | |||
| 206 | PUBWEAK ADC1_COMP_IRQHandler |
||
| 207 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 208 | ADC1_COMP_IRQHandler |
||
| 209 | B ADC1_COMP_IRQHandler |
||
| 210 | |||
| 211 | PUBWEAK TIM1_BRK_UP_TRG_COM_IRQHandler |
||
| 212 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 213 | TIM1_BRK_UP_TRG_COM_IRQHandler |
||
| 214 | B TIM1_BRK_UP_TRG_COM_IRQHandler |
||
| 215 | |||
| 216 | PUBWEAK TIM1_CC_IRQHandler |
||
| 217 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 218 | TIM1_CC_IRQHandler |
||
| 219 | B TIM1_CC_IRQHandler |
||
| 220 | |||
| 221 | PUBWEAK TIM2_IRQHandler |
||
| 222 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 223 | TIM2_IRQHandler |
||
| 224 | B TIM2_IRQHandler |
||
| 225 | |||
| 226 | PUBWEAK TIM3_IRQHandler |
||
| 227 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 228 | TIM3_IRQHandler |
||
| 229 | B TIM3_IRQHandler |
||
| 230 | |||
| 231 | PUBWEAK TIM6_DAC_IRQHandler |
||
| 232 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 233 | TIM6_DAC_IRQHandler |
||
| 234 | B TIM6_DAC_IRQHandler |
||
| 235 | |||
| 236 | PUBWEAK TIM7_IRQHandler |
||
| 237 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 238 | TIM7_IRQHandler |
||
| 239 | B TIM7_IRQHandler |
||
| 240 | |||
| 241 | PUBWEAK TIM14_IRQHandler |
||
| 242 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 243 | TIM14_IRQHandler |
||
| 244 | B TIM14_IRQHandler |
||
| 245 | |||
| 246 | PUBWEAK TIM15_IRQHandler |
||
| 247 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 248 | TIM15_IRQHandler |
||
| 249 | B TIM15_IRQHandler |
||
| 250 | |||
| 251 | PUBWEAK TIM16_IRQHandler |
||
| 252 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 253 | TIM16_IRQHandler |
||
| 254 | B TIM16_IRQHandler |
||
| 255 | |||
| 256 | PUBWEAK TIM17_IRQHandler |
||
| 257 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 258 | TIM17_IRQHandler |
||
| 259 | B TIM17_IRQHandler |
||
| 260 | |||
| 261 | PUBWEAK I2C1_IRQHandler |
||
| 262 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 263 | I2C1_IRQHandler |
||
| 264 | B I2C1_IRQHandler |
||
| 265 | |||
| 266 | PUBWEAK I2C2_IRQHandler |
||
| 267 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 268 | I2C2_IRQHandler |
||
| 269 | B I2C2_IRQHandler |
||
| 270 | |||
| 271 | PUBWEAK SPI1_IRQHandler |
||
| 272 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 273 | SPI1_IRQHandler |
||
| 274 | B SPI1_IRQHandler |
||
| 275 | |||
| 276 | PUBWEAK SPI2_IRQHandler |
||
| 277 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 278 | SPI2_IRQHandler |
||
| 279 | B SPI2_IRQHandler |
||
| 280 | |||
| 281 | PUBWEAK USART1_IRQHandler |
||
| 282 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 283 | USART1_IRQHandler |
||
| 284 | B USART1_IRQHandler |
||
| 285 | |||
| 286 | PUBWEAK USART2_IRQHandler |
||
| 287 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 288 | USART2_IRQHandler |
||
| 289 | B USART2_IRQHandler |
||
| 290 | |||
| 291 | PUBWEAK USART3_8_IRQHandler |
||
| 292 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 293 | USART3_8_IRQHandler |
||
| 294 | B USART3_8_IRQHandler |
||
| 295 | |||
| 296 | PUBWEAK CEC_CAN_IRQHandler |
||
| 297 | SECTION .text:CODE:NOROOT:REORDER(1) |
||
| 298 | CEC_CAN_IRQHandler |
||
| 299 | B CEC_CAN_IRQHandler |
||
| 300 | |||
| 301 | END |
||
| 302 | ;************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE***** |