Jump to content

Flash programming in ASM

Recommended Posts

Hello All,


I am trying to write data into flash which i need to copy it to the SRAM later. I am doing this in assembly and this is part of the code i am trying to use.


I have provided the addresses of the FMD, FMA and FMC registers needed for flash programming and then I am copying those addresses into the registers r8,r9 and r10.


My question is how do i now load data values into the addresses pointed by the registers r8,r9 and r10? As you can see, I am clearly wrong somewhere and need assistance!!


FMD   EQU 0x000000AB
FMA  EQU 0x000000DC
FMC   EQU 0x000000FF
MOV32 [R8], #0xF0F0F0F0
MOV32 R9, #0x00000000
MOV32   R10,#0xA4420001
BNE poll
Link to post
Share on other sites


It will be a little cheating, but for learning purposes will work, as long as nobody knows what you have done: just compile the driverlib routine write_to_flash, generate a listing and try to understand how the writing should be done, then adapt it for your needs.


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...