Arm Community
Site
Search
User
Site
Search
User
Support forums
Arm Development Studio forum
ARM assembler register read
Jump...
Cancel
Locked
Locked
Replies
5 replies
Subscribers
119 subscribers
Views
7812 views
Users
0 members are here
Options
Share
More actions
Cancel
Related
How was your experience today?
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
ARM assembler register read
Dennis Gabler
over 12 years ago
Note: This was originally posted on 11th September 2010 at
http://forums.arm.com
Hello All,
I need a quick example of how to place a value from a hardware register (0x70001234 for example) into a register such as R0
then compare it to a constant such as 0xE0680003 and do a branch based on equality.
So far I have had no luck getting something this simple to work.
Thanks,
Dennis
Parents
MARIO VISPERAS
over 12 years ago
Note: This was originally posted on 14th September 2010 at
http://forums.arm.com
ldr r1, =(SBMR)
--> This code will not read a RAM/Peripheral register. The parenthesis is treated by the assembler to contain an equation of sorts that eventually results to a constant. Thus, this code boils down to ldr, r1, = constant.
See my example and study it. Also read the Assembly instruction sets manual from ARM. The books by Sloss and Hohl are very good place to start with.
Cancel
Vote up
0
Vote down
Cancel
Reply
MARIO VISPERAS
over 12 years ago
Note: This was originally posted on 14th September 2010 at
http://forums.arm.com
ldr r1, =(SBMR)
--> This code will not read a RAM/Peripheral register. The parenthesis is treated by the assembler to contain an equation of sorts that eventually results to a constant. Thus, this code boils down to ldr, r1, = constant.
See my example and study it. Also read the Assembly instruction sets manual from ARM. The books by Sloss and Hohl are very good place to start with.
Cancel
Vote up
0
Vote down
Cancel
Children
No data