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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
09/07/00 09:56
Read: times


 
#4938 - 8031 hanging during delay routine
All...

I am having a problem with my 8031, (and related circuit), hanging during a delay routine, it is as follows:

LONG_DELAY:
mov r5, #00h
TIME:
mov r4, #00h
WASTE:
djnz r4, WASTE
djnz r5, TIME
ret

I have used many variations to this code (including code extracted from working programs) and still have not been able to rectify the problem. There was one single occasion that I was able to get the delay to return from my subroutine, when I changed the value in R5 to #04h. The registers specified are not used on any other occasion.
I am using the MCS-51 assembler ver 1.2, whether or not this has something to do with my problem, and a 12 MHz Xtal. Does ANYBODY have any input??? Thanx in advance for the help.

Ben House



List of 16 messages in thread
TopicAuthorDate
8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      
RE: 8031 hanging during delay routine            01/01/70 00:00      

Back to Subject List