Differences
This shows you the differences between two versions of the page.
packed_bcd_addition [2016/06/01 17:04] ex_writer created |
packed_bcd_addition [2016/06/01 17:05] ex_writer |
||
---|---|---|---|
Line 10: | Line 10: | ||
or A | or A | ||
ret z ;test whether length = 0 | ret z ;test whether length = 0 | ||
- | Loop: | + | Loop: ld A, (DE) ;get byte of adder |
- | ld A, (DE) ;get byte of adder | + | |
adc A, (HL) ;add it to addend, care for carry | adc A, (HL) ;add it to addend, care for carry | ||
daa ;convert to BCD-decimal | daa ;convert to BCD-decimal |