Google

Jun 23, 2008

Adding the 4 four most significant bit to a hexa no

this is the program to add 4 most significant bit to a hexa decimal number

first get most significant BCD Digit
then move to the location by RLC command
store the temporary number in C
get the lower BCD digit and add it
store the result and stop the program.

LDA 2201H
RLC
RLC
RLC
RLC
MOV C,A
LDA 2200H
ADD C
STA 2300H
HLT

No comments: