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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
08/07/02 03:31
Read: times


 
#26865 - simple question on ASM DJNZ command
I've been trying to determine when a DJNZ loop is halted. For example, does the DJNZ loop subtract one and then check its value, or does it check the value, and if its not zero, subtract one and loop.

If this was the program :

MOV R5, #1
MOV A, #1

Internal_Loop:
ADD A, #1
DJNZ R5, Internal_Loop

End

Basically what I'm asking is "At the end of this program loop, would A be 2 or 3?"

List of 16 messages in thread
TopicAuthorDate
simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
I agree            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question on ASM DJNZ command            01/01/70 00:00      
RE: simple question ,erik,george            01/01/70 00:00      
RE: simple question ,erik,george,corexon            01/01/70 00:00      
RE: simple question ,erik,george,corexon            01/01/70 00:00      
RE: simple question ,erik,george,corexon            01/01/70 00:00      
RE: simple question ,erik,george,corexon            01/01/70 00:00      

Back to Subject List