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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
03/30/04 16:54
Read: times


 
#67633 - RE: mistake in my code
Responding to: ???'s previous message
Hello All,
Look at her post using the "quote text" and this is what
you will see. It would appear she did format her code.
It look straight forward to me (and Oleg) without comments.
Good going Lisa.
Good luck,
Charles Bannister
Lisa Hansen wrote:
-------------------------------
Hi,
There is a mistake in this program at some point after
the lable XRAM: ,I am trying to copy address 50h thru 
5fh to xram locations 2000h thru 200fh. Any ideas where 
I am going wrong? The program is a kind of 
bubblesort.Thank you.

.ORG 2010H
MOV DPTR,#0010H             
MOV R0,#40H                 
MOV R1,#50H                 
MOV R7,#16                  
GET:CLR A
    MOVC A,@A+DPTR          
    MOV @R0,A               
    MOV @R1,A
    INC DPTR                
    INC R0                  
    INC R1
    DJNZ R7,GET
LOOP1:MOV R7,#15            
      MOV R5,#00H           
      MOV R0,#50H           
LOOP2:MOV A,@R0             
      MOV R6,A              
      INC R0                
      CLR C
      SUBB A,@R0            
      JNC MOVE              
      SJMP COUNT            
MOVE:MOV A,@R0              
     DEC R0                 
     MOV @R0,A              
     MOV A,R6               
     INC R0                 
     MOV @R0,A              
     INC R5                 
COUNT:DJNZ R7,LOOP2
      CJNE R5,#00H,LOOP1    
XRAM:MOV DPTR,#2000H        
     MOV R0,#50H            
     MOV R7,#16             
MOVE2:MOV A,@R0             
      MOVX @ DPTR,A         
      INC R0                
      INC DPTR              
      DJNZ R7,MOVE2
      LJMP 0000
      ;END


List of 19 messages in thread
TopicAuthorDate
mistake in my code            01/01/70 00:00      
   RE: mistake in my code            01/01/70 00:00      
   RE: mistake in my code            01/01/70 00:00      
      RE: mistake in my code            01/01/70 00:00      
         RE: mistake in my code            01/01/70 00:00      
      RE: mistake in my code            01/01/70 00:00      
         RE: mistake in my code            01/01/70 00:00      
            RE: mistake in my code            01/01/70 00:00      
               RE: mistake in my code            01/01/70 00:00      
         RE: mistake in my code            01/01/70 00:00      
            RE: mistake in my code            01/01/70 00:00      
   RE: mistake in my code            01/01/70 00:00      
   RE: mistake in my code            01/01/70 00:00      
      RE: a comment on comments            01/01/70 00:00      
      RE: mistake in my code            01/01/70 00:00      
         RE: mistake in my code            01/01/70 00:00      
      Comments            01/01/70 00:00      
         RE: Comments            01/01/70 00:00      
            RE: Comments            01/01/70 00:00      

Back to Subject List