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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
10/26/02 16:27
Read: times


 
#31461 - RE: COMPARE RESGISTER
To all readers:

The above post from Mr. Eric Malund has a flaw in it. The correct usage is given below.
============================
Eric wrote:
you are missing the full use of CJNE
mov a,r4
cjne a,r5,check
; r4,r5 are equal
....
check: jc R5isGreater
; r4 > r5
...
===========================
There is a flaw in this code. The C flag
has to be clear before the cjne can be run
to insure the JC instruction is performed
correctly.
===========================
Should be:
CLR C
MOV A,R4
CJNE A,R5,check
; R4,R5 are equal
....
check: JC R5isGreater
; R4 > R5
...
==========================
Regards,

Charles Bannister

List of 14 messages in thread
TopicAuthorDate
COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER Charles            01/01/70 00:00      
RE: COMPARE RESGISTER            01/01/70 00:00      
RE: COMPARE RESGISTER Charles            01/01/70 00:00      
RE: COMPARE RESGISTER - correction            01/01/70 00:00      
RE: COMPARE RESGISTER - correction            01/01/70 00:00      

Back to Subject List