cancel
Showing results for 
Search instead for 
Did you mean: 

STM32WB OTA SCB->VTOR

rs-dp
Associate II

Hi,

I need to add OTA functionality to a CubeMX generated project. The readme.txt file from the BLE_HeartRate_ota project has a note saying "Remove the update of SCB->VTOR in the file system_stm32wbxx.c". On my current CubeMX generated project the SCB->VTOR line is protected with a macro as follows:

 

#if defined(USER_VECT_TAB_ADDRESS)
  /* Configure the Vector Table location add offset address ------------------*/
  SCB->VTOR = VECT_TAB_BASE_ADDRESS | VECT_TAB_OFFSET;
#endif /* USER_VECT_TAB_ADDRESS */

 

I am using CubeIDE and noticed that this macro is not defined by default, which doesn't make sense.

  1. Where is the VECT_TAB_BASE_ADDRESS defined?
  2. Is it OK to use another define macro to disable the line instead of deleting it? Asking this because comparing the BLE_HeartRate vs BLE_HeartRate_ota the lines were completely removed.
1 ACCEPTED SOLUTION

Accepted Solutions
STTwo-32
ST Employee

Hello @rs-dp 

1) #define VECT_TAB_BASE_ADDRESS is on the system_stm32wbxx.c file.

2) I suggest you follow exactly the recommendation of the Over-the-air application and wireless firmware update for STM32WB series microcontrollers - Application note part 4.1.1 

STTwo32_0-1716490666557.png

Best Regards.

STTwo-32

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

1 REPLY 1
STTwo-32
ST Employee

Hello @rs-dp 

1) #define VECT_TAB_BASE_ADDRESS is on the system_stm32wbxx.c file.

2) I suggest you follow exactly the recommendation of the Over-the-air application and wireless firmware update for STM32WB series microcontrollers - Application note part 4.1.1 

STTwo32_0-1716490666557.png

Best Regards.

STTwo-32

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.