cancel
Showing results for 
Search instead for 
Did you mean: 

Problem about STM32F301 IAP.

kang hu
Associate
Posted on April 04, 2018 at 07:59

Hi?I encountered a strange problem in my iap bootloader project.

There are two project for my application, the first is for ota. the second is for the universal task.

when the board is powered. The first project is active. I read the flash to decide whether to jump to the second project.

In the Keil v5. I set the ROM addr as 0X08000000  size 0x5800 for the first project, and set the ROM addr 0X08005800 size 0XA800.

I found the static volatile int variable in first project configed as 0 was changed to 256 by the second project sometimes.

Strangely, The problem became in 4 boards of 100 randomly.

I tryed to set different ram area for the two projects. But, it�s not ok.

Would you help me to analyze the strange problem?

Best Wishes,

Kang Hu

#stm32-c-programming #stm32f3
1 REPLY 1
Posted on April 07, 2018 at 17:16

For commercial work ST has a list of consultants and contractors.

You'd want to do some debugging, looking particularly at the heap, and the stack depth, as it is likely to descend through the heap, statics, locale, etc.

Instrument things and have sanity checking for the variables so you identify when the failure first occurs. When passing data consider containing all of it within a structure that you can checksum, and abstract access to those values to a couple of subroutines.

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