cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H743: The jump from startup to main does not occur. An unknown interrupt is repeatedly executed.

taku_hat
Associate

Hello.

An inexplicable bug occurs during the transition from startup_stm32h743xx.s to main, causing unnecessary functions to be repeatedly executed.

An unknown function (I2C_IsErrorOccurred) continues to be called. It is strange that it is being invoked despite no initialization being performed.

 

I believe that fixing this bug requires identifying the cause of the repeated calls to an unknown address, but I lack sufficient knowledge to do so

I need the help of someone knowledgeable.


IDE:
μVision V5.40.0.0
Toolchain: MDK Plus 5.40 : 5.40.0.3
C Compiler: ArmClang.exe V6.22
Assembler: Armasm.exe V6.22
Linker/Locator: ArmLink.exe V6.22
Library Manager: ArmAr.exe V6.22
Hex Converter: FromElf.exe V6.22
CPU DLL: SARMCM3.DLL V5.40.0.3
Dialog DLL: TCM.DLL V1.56.4.0
Target DLL: ULP2CM3.DLL V2.215.24.0
Dialog DLL: TCM.DLL V1.56.4.0

 

I haven't made any particular changes to the linker, startup, or system initialization, and I am using the default address 0x80000000.

2 REPLIES 2
mƎALLEm
ST Employee

Hello,

What is the origin of your code? generated by CubeMx? An example from CubeH7? What is the board you are using? ST board? Custom board? if ST board which one?

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.
TDK
Guru

The compiler is quite robust. It's unlikely to be doing things that are not present in the code. Similarly, the chip does not behave erratically and execute functions that it should not.

If I2C_IsErrorOccurred is called, set a breakpoint and examine the state of the chip to determine why it's called. Look at VECTACTIVE in SCB->ICSR to determine which interrupt the chip thinks it's in. Examine the registers of the relevant peripheral to determine why it's been called. I2C_IsErrorOccurred is not a direct IRQ handler, so look at the call stack to understand how it was called.

In any case we're unlikely to be able to help here unless you provide additional information on the problem. A minimal working example which exhibits the problem, or relevant screenshots and code showing the issue.

If you feel a post has answered your question, please click "Accept as Solution".