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

uVision debugger problem

I'm working with the Silab C8051F930.
this is the code i can see in the debugger

    83:   SPI1DAT =  biDataIn ;                         // write data register
C:0x3848    8F86     MOV      B_Enrgy_TH(0x86),R7
    84:   while (!TXBMT1);                              // wait on TXBMT
C:0x384A    30B1FD   JNB      TXBMT1(0xB0.1),C:384A
    85:   while ((SPI1CFG & M_SPIBSY1) == M_SPIBSY1);   // wait on SPIBSY
C:0x384D    E584     MOV      A,SPI1CFG(0x84)
C:0x384F    20E7FB   JB       0xE0.7,C:384D
    86:   bValue = SPI1DAT;                             // read value
C:0x3852    858616   MOV      0x16,B_Enrgy_TH(0x86)
    87:   SPIF1 = 0;                                    // leave SPIF cleared
    88:

SPI1DAT (line 83) is expressed as B_Enrgy_TH(0x86).
SPI1DAT is indeed SFR (0x86) in SFR page 0x0. it is not clear where from this register got the name B_Enrgy_TH. i have no such varaible in the program.
i did use such variable in previous project, but how is it popping up hear?
besides, the main issue is when i check SPI1DAT i see it doesn't get the value i write into it.

any idea for the reason?

0