When I first call WaitHalfSec do the lines in labels L3, L2, L1 also get read? When "djnz, R2" calls L3 do all lines below L3, including L2 and L1, get read again or does it only read L3 and return? Because if it does, it seems like it'd be an infinite loop? Any help is appreciated.
When I first call WaitHalfSec do the lines in labels L3, L2, L1 also get read? When "djnz, R2" calls L3 do all lines below L3, including L2 and L1, get read again or does it only read L3 and return? Because if it does, it seems like it'd be an infinite loop? Any help is appreciated.
No problem with infinite loop ..
The program is executed as follows:
R2 is loaded with #30
R1 is loaded with #250
and
R0 is loaded with #250
Next within loop L1 R0 is decreased 250 times ..
Then the program looks at loop L2 and executes it 250 times with loop L1 being executed as described above ..
Then it looks at loop L3 and executes it 30 times executing internal loops L2 (250 times) and within it loop L1 (250 times) ..
After L3 loop is completed the program exits/returns ..