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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
04/22/08 12:18
Read: times


 
#153820 - Here iis a hint:
Responding to: ???'s previous message
Jesmond Bezzina said:
HELLO GUYS,

MY CODE WAS THIS:

  MOV SP,#256-32 

  MOV R1,#30H 
  MOV A,#01H 
  MOV R2,#00H
LOOP1:MOV @R1,A 
  ADD A,R2
  MOV R2,A
  INC A 
  INC R1 
  AJMP LOOP0 

LOOP0: CJNE R1,#34H,LOOP1 

  MOV @R1,A 
  MOV 25H,R2
  END 



check your instructions for "MOV destination,source"
check for redundant instructions. ( no harm, just unnecessary )
Hint: one incorrect and three redundant.

You can easily get help now that you show that you have made your own attempt. First thing is to always indent your code.

David.



List of 18 messages in thread
TopicAuthorDate
Registers and data movment.            01/01/70 00:00      
   ...replace this with your code...            01/01/70 00:00      
      IDEA            01/01/70 00:00      
         Any idea...            01/01/70 00:00      
            I bet if your instructor knew about this...            01/01/70 00:00      
               Too bad ...            01/01/70 00:00      
                  In the UK...            01/01/70 00:00      
                     if they told ...            01/01/70 00:00      
   my CODE            01/01/70 00:00      
      Here iis a hint:            01/01/70 00:00      
      how is that ever going to stop ?            01/01/70 00:00      
   i'VE GOT THE CODE!!!!            01/01/70 00:00      
      Please use the insert code button!            01/01/70 00:00      
         Is "well structured" code ...            01/01/70 00:00      
            comment            01/01/70 00:00      
               then, why don't you ?            01/01/70 00:00      
         Acall            01/01/70 00:00      
            Acall???            01/01/70 00:00      

Back to Subject List