Guest
#2749395
Hello,
I use gcc to compile my code for STM32F407VGT6. I am trying to print the
value of PC register and in order to do this I use this code:
unsigned int pc_value;
__asm__("mov %%R15,%0" : "=r" (pc_value));
My application crashes when it executes this line. If I replace R15 with
another register (R1 for example) it does not crash anymore.
Is this because I am not allowed to read the value of PC ?
Thanks.