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

Help using DPPs please

Hi there,

While I understand how DPPs are used physically, I am having some trouble actually trying to use them in code! Here is a particular example I am stuck on, I have simplified it so hope I didn't leave anything out:

Boot_block SECTION CODE WORD 'Boot_Code' ; Located at 0x6000

version db 1 ; A constant located at 0x6000

init_boot PROC NEAR

mov r0, #version ; Move the address 0x6000 (constant) into R0

/\ This line wont assemble. Says "missing DPP information". I am not sure why it needs DPP information to simply load the address into a register as a constant??? This should translate to a mov r0, immediate instruction correct? If I add the following lines above the line that wont assemble as a test, the problem goes away. But, I don't want a DPP pointing at page 1!!! Can anyone explain please?

ASSUME DPP0 : boot_block ; Assume DPP0 points to page 1 (0x4000-0x7FFF)
mov DPP0, #1

  • Just to add a bit more... I found that using the following lines assembles fine:

    mov r0,#POF FWB_Version_L ; R0 has 14 bit offset of variable
    extp #PAG FWB_Version_L, #1 ; Force read from data page where variable lives for one instruction
    movb rl5,[r0]

    I would still like an explanation if anyone has one and any other help or hints on using the DPP registers. Until now our project has only used a TINY model and now we need to alter everything to use more of the address space...