AnsweredAssumed Answered

How to get initial MSP and PC values?

Question asked by Carter Lee on Feb 23, 2018
Latest reply on Feb 23, 2018 by Clive One

Hi.

I'm trying to get the MSP and PC values in the example of STM32F4 firmware.

How can I do to get the Main stack pointer and Program counter value?

 

 

I came across the below snippet code from ARM Information Center 

 

int f(int x)
{
int r0;
__asm
{
ADD r0, x, 1
EOR x, r0, x
}
return x;
}

 

but I can't see the that function whether work as well or not, because break point doesn't work in uVision.

 

Would you please let me know how to do to get the  MSP and PC value ?

Also how do set the breakpoint into the f function? in my case when I set the breakpoint by using F9 function key, that break point doesn't work.

Outcomes