This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Unexpected SVC interrupt caused by os_sys_init on stm32f446RxTx

Hi everyone,

I am working on two devices: stm32f446RETx and stm32f446RCTx, the only difference between these devices is the flash memory size (512K and 256K).
I am trying to get a same executable code on both references for double sourcing matters.
I have a code with a bootloader and an application.
The application runs with  RTX os.
I have a scatter file for the application code which limits the application location in order to keep a compatible hex file for STM32f446RCT (which have the smallest memory).

Everything works correctly when I set the project device with stm32f446RETx and on run it on a stm32f446RETx .

However when I compiled the project seting stm32f446RCT device and runs it on the stm32f446RET (which should not be a problem since only the flash memory size is different) the os_sys_init function jump into the weak SVC interrupt of the bootloader.
I do not use this interrupt in any case, and I do not have this issue when I compile for stm32f446RET and runs the code on stm32f446RET.
I will soon get a board with stm32f446RCT to try the opposite (stm32f446RET compilation running on stm32f446RCT device).

I am sure it is not a memory size issue, but I am wondering what could be the cause of it ?
When I compile the same application for stm32f446RCT without the use of the bootloader and runs it on the stm32f446RET device it works perfectly as well.
The bootloader itself works on stm32f446RET either it was compiled for stm32f446RET or stm32f446RCT.

I do not realy know how to solve this. Any ideas ?

Best regards

Parents
  • Perhaps try minimizing the application to see if it still fails (just empty main toggling an LED or similar).

    If it does not fail, try enabling other pieces of code until you get it to fail and see what seems to be the cause.

Reply
  • Perhaps try minimizing the application to see if it still fails (just empty main toggling an LED or similar).

    If it does not fail, try enabling other pieces of code until you get it to fail and see what seems to be the cause.

Children