AnsweredAssumed Answered

Code not going directly to main loop

Question asked by cooke.ernest on Jun 22, 2017
Latest reply on Jul 5, 2017 by holt.tony

Hi,

 

I am currently in the process of converting project code I have using the Standard peripheral library to the Hardware Abstraction Layer (HAL).

 

I noticed that when I try to debug the code and place a breakpoint in the main loop that the code does not go directly to the main loop when I press the 'Run' (F5) button in Keil uVision.  The 'Run' button instead must be pressed 4 times before it goes to the main loop.

 

 

Before the code goes to the main loop, it is caught in the following location in the startup file.

 

 

After this I can get the code to execute a basic function i.e. blink an LED.  

However when I try to execute the code in standalone mode it does not work.

 

When I tried this code using the Standard peripheral library, it went directly to the main loop the first time I pressed the 'Run' button in debug mode and it worked fine in standalone mode i.e. I got the LED to blink.

 

Does anyone have any suggestions as to what the issue might be or how I could solve it?

 

Kind Regards,

Ernest

Outcomes