Skip to main content
taraben
Associate III
February 6, 2016
Question

cubemx stm32 feature request: support custom VECT_TAB_OFFSET

  • February 6, 2016
  • 7 replies
  • 1202 views
Posted on February 06, 2016 at 23:01

Hello,

while dealing with custom bootloader we have to switch application to certain offset address.

Thus we have to move the address of the vector table.

While HSE values are supported to be customized vector table offset is not.

please add following lines to the system_stm32xxxx.c files:

/* &sharpdefine VECT_TAB_SRAM */

---> &sharpif !defined(VECT_TAB_OFFSET)

&sharpdefine VECT_TAB_OFFSET  0x00 /*!< Vector Table base offset field.

                                   This value must be a multiple of 0x200. */

---> &sharpendif

Thanks, Regards,

Adib.

/******************************************************************************/

#cubemx-stm32-hal
This topic has been closed for replies.

7 replies

Nesrine M_O
Associate
February 8, 2016
Posted on February 08, 2016 at 09:23

Hi adib,

Thanks for the suggestion! I will forward this to our team.

-Syrine-

kevin2399
Associate III
February 12, 2016
Posted on February 12, 2016 at 19:43

I second adib's request.

stm32cube-t
ST Employee
February 23, 2016
Posted on February 23, 2016 at 15:47

Hello,

Thank you for your post.

This enhancement is already planned and shall be ready for deployment this semester as part of STM32Cube embedded software official releases.

 

Best regards
taraben
tarabenAuthor
Associate III
February 27, 2016
taraben
tarabenAuthor
Associate III
April 3, 2017
Posted on April 03, 2017 at 13:34

Hello All,

still this Bug exists:

STM32CubeMX 4.20 + STMCubeF4 1.15

When I program for my custom bootloader layout, I do have to move the vector table.

Very anoying bug.

please fix.

Adib.

--

Tesla DeLorean
Guru
April 3, 2017
Posted on April 03, 2017 at 17:31

They should just stop using the define, and get the linker to do this using a symbol for the Vector Table, it's what sane people do...

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
Morty Morty
Associate III
August 20, 2018

And it's not even a

#ifndef VECT_TAB_OFFSET
#define VECT_TAB_OFFSET 0
#endif 

:crying_face: And as it's not part of the template engine I can't even use that to fix this... -> Running patch as part of the make process it is....

Tesla DeLorean
Guru
August 20, 2018

It's stupid by design, people with any conception of how compilers/linkers work would have used a symbol from the outset. Defining things in multiple places is a recipe for failure. The linker in this situation determines the "built-at" address.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..