We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
I am new to the arm & I was writting the code in keil to store the number using DCD but i am unable to store it & instead it just store some number so where is my code wrong?area prog1,code,readonly entry ldr r1,=0x4020 ldr r2,=label str r2,[r1]label DCD 0xAEF67D90 end
Hi,
ldr r2,=label
would be wrong.
By this code, the address of the label will be loaded into r2.
If you want to load the content of the label, you should remove '=' as
ldr r2,label.
HTH,
Yasuhiko Koumoto.