uVision2 Debug Fn: Access to Extended Registers

I am using a Triscend TE505 (with 2 Data Pointers).
In addition to the standard set, the debugger Registers window adds the following under 'Sys':

Sys
 |
 :
 +--auxr1
 |
 +--dptr
 |   |
 |   +--[0]
 |   |
 |   +--[1]
 :
I assume that 'auxr1' is the Triscend DPS (Data Pointer Select) register.

The Function Editor does not recognise these names:
FUNC void ShowRegs( void ) 
{
    :
    printf( "  %02x", AUXR1 ); 
______________________^
*** error 34, line 18: undefined identifier
    printf( "%04x", DPTR[0] ); 
*** error 46, line 19: subscript requires array
    printf( "%04x", DPTR[1] ); 
*** error 46, line 19: subscript requires array
    printf( "\n" );
}
So, how can I access these extended registers from a Debug Function?

Parents
  • There is only one address for DPTR. So, the only way to change the DPTR in your program is to change the DPS register (which selects the DPTR) and then change the DPTR.

    To change the contents of a register in the REG window, click on the line with the register. Then, wait a second or two and click again (do not double-click).

    A box appears where you can type in the new value.

    Jon

Reply
  • There is only one address for DPTR. So, the only way to change the DPTR in your program is to change the DPS register (which selects the DPTR) and then change the DPTR.

    To change the contents of a register in the REG window, click on the line with the register. Then, wait a second or two and click again (do not double-click).

    A box appears where you can type in the new value.

    Jon

Children
More questions in this forum