•Write
an 80486 ALP that will add the two nibbles in a data byte together and if there
is a carry in the nibble addition it will write ‘C’ into a memory location. If
there is no carry in nibble addition it will write ‘N’ into the location. This
has to be done on array of 25d data bytes stored from location dat1. The result
for each byte must be written from location car1.
For E.g. If
dat1 db 45h,89h,27h, 0F2h, 3Eh and
so on
The
program
has to add 4 and 5 in case of first byte and there will be no carry in adding
the two nibbles (4-bit addition) so N has to be written into car1 and if case
of 2nd data 8 and 9 will be added and result will have a carry in the nibble
addition so C will be written into next location.
Hence
after
the program is executed the location
car1
will
have the values ‘N’, ‘C’, ‘N’,’C’,’C’ and so on