cancel
Showing results for 
Search instead for 
Did you mean: 

The vector-table defined in the startup code(startup_stm32f10x_cl.s, the gcc version)

gl
Associate
Posted on November 14, 2013 at 06:40

There is a vector-table defined in the ''startup_stm32f10x_cl.s''(the gcc version):

.section .isr_vector,''a'',%progbits

.type g_pfnVectors, %object

.size g_pfnVectors, .-g_pfnVectors

g_pfnVectors:

.word _estack

.word Reset_Handler

.word NMI_Handler

.word HardFault_Handler

My question is: what's the result of the .size directive sentence? I think maybe it's 0, because the '.' symbol and the 'g_pfnVectors' label may represent the same address:

.size g_pfnVectors, .-g_pfnVectors

Then what's the function of this sentence, if its result is 0?

Another question is about the last item of this table:

.word BootRAM /* @0x1E0. This is for boot in RAM mode for STM32F10x Connectivity line Devices. */

What's the purpose of this?

1 REPLY 1
Posted on November 14, 2013 at 14:22

With regard to your second question, when booting from RAM the processor appears to ignore the PC vector, and jumps to a specific address at the end of the vector table. The fix is to code an instruction to do a PC load with the word at +4

When booting from FLASH there isn't such an issue.
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..