Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
06/27/08 04:48
Read: times


 
#156234 - Assembler Dump
Responding to: ???'s previous message
Hi

sorry for the delay.

after I changed the variable to data instead of xdata, then problem shifted to some other variable. now I changed that too.
but do not know which variable will be affected.


Assmebler code for assigning of variable with different memory types.
------------------------------------------
xdata unsigned char LockingStatus;
-----------------------------------------

c code line : LockingStatus = 1;
; SOURCE LINE # 242
; SOURCE LINE # 243
035A 900000 R MOV DPTR,#LockingStatus
035D 7401 MOV A,#01H
035F F0 MOVX @DPTR,A



--------------------------------------------------------
data unsigned char LockingStatus
--------------------------------------------------------

c code line : LockingStatus = 1;
; SOURCE LINE # 242
; SOURCE LINE # 243
0352 750001 R MOV LockingStatus,#01H

----------- end of assembler code
I am zero in assembly language. so i do not understand what is going on in the above code. so dont know whether it is correct or not. please advice.

I also want to know, when declaring variables, whether we need to follow any definite order, like declare 'data' variables first, then declare 'xdata' variables etc ?

this is not isolated problem. it happened some time back also.
suddenly working program decomes like this and I do some patch work to make it work.

but I never diagonised the root cause of the problem. I must do it now. I do not have debugging tools either.

when I display the value of the variable in terminal it shows zero not the assigned value.

Haribabu




List of 18 messages in thread
TopicAuthorDate
Strange problem with Keil Compiler            01/01/70 00:00      
   Try volatile            01/01/70 00:00      
      Probably not the volatile            01/01/70 00:00      
         Who can know what is in the mind of the compiler            01/01/70 00:00      
   cut out the optimizer (set to 2) and see            01/01/70 00:00      
   Assembler Dump            01/01/70 00:00      
      well            01/01/70 00:00      
         XRAM is enabled            01/01/70 00:00      
            the most likel7y reason is that            01/01/70 00:00      
            You may want to let the linker know            01/01/70 00:00      
               he is using a '124            01/01/70 00:00      
                  I know            01/01/70 00:00      
               Linker output            01/01/70 00:00      
                  OVERLAYABLE            01/01/70 00:00      
                  OVERLAYABLE ?            01/01/70 00:00      
      Eh, no debugger for silabs chip?            01/01/70 00:00      
         I am using CA51 which dont have debugging            01/01/70 00:00      
            it will            01/01/70 00:00      

Back to Subject List