Please note: We are aware of an issue affecting replies on the Arm Community forums, which may not be loading as expected.

We apologize for any inconvenience and appreciate your patience while we investigate and work to resolve the issue.

Thank you for your understanding.


This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Problem with Writing on Registers ARM Cortex-M7 (FVP)

Hi, I am trying to write a really simple syntax in Arm Development Studio to write a value on two of the registers, R0 and R1.
In command line and Registers section, I can see no change in any of the values.
I tried using other registers in FP or even System registers, nothing changed!

Here is my code:

#include <stdio.h>

#include <stdlib.h>

int main(void) {

printf("!!!Hello World!!!"); // prints !!!Hello World!!!

// Inline assembly to set R0 and R1 with known values.

__asm volatile (

"mov r0, #0x1234 \n\t" // Load R0 with 0x1234

"mov r1, #0x5678 \n\t" // Load R1 with 0x5678

);

// Infinite loop to allow time for inspection.

while (1) {

}

return 0;

}



Parents Reply Children