daa decimal adjust accumulator instruction


DAA Decimal Adjust Accumulator Instruction

This  instruction adjusts the contents  of the accumulator  into BDC (Binary Coded Decimal )  form  after a BCD  addition. It should be  used after ADD, ADI etc instruction if performing  BCD  addition  the  instruction format is

DAA

This is the only instruction which  uses auxiliary carry flag internally.

Flag: All flags  are moodier according  t the result.

 Followings  procedure is used by DAA instruction to convert the contents of th e accumulator from binary  to BCD.

a.If the value of  low order  four bits (D3 -D0)  in the accumulator of the accumulator  9 the instruction adds  6  to the low order four bits.

b.If the value of high  order four bits  (D7-D4)  in the accumulator  is more  than 9 the instruction adds  6 to the high  order four bits

See followings  example to understand the  working  of DAA instruction.

Request for Solution File

Ask an Expert for Answer!!
Electrical Engineering: daa decimal adjust accumulator instruction
Reference No:- TGS0412002

Expected delivery within 24 Hours