Write programs that will accomplish the desired tasks listed below, using as few lines of code as possible. a) Add the bytes in RAM locations 34H and 35H ; put the result in register R5 (LSB) and R6 (MSB) b) Subtract the content of R2 from the number F3H ; put the result in external RAM location 028BH. c) Subtract the content of R1 from R0 ; put the result in R7. d) Multiply the data in RAM location 22H by the data in RAM location 15H ; put the result in RAM location 19H (low byte) and 1AH (high byte).
Write programs that will accomplish the desired tasks listed below, using as few lines of code as possible.
a) Add the bytes in RAM locations 34H and 35H ; put the result in register R5 (LSB) and R6 (MSB)
b) Subtract the content of R2 from the number F3H ; put the result in external RAM location 028BH.
c) Subtract the content of R1 from R0 ; put the result in R7.
d) Multiply the data in RAM location 22H by the data in RAM location 15H ; put the result in RAM
location 19H (low byte) and 1AH (high byte).
e) Divide the data in RAM location 3EH by the number 12H ; put the quotient in R4 and the remainder
in R5.
f) Divide the data in RAM location 15H by the data in RAM location 16H ; put the quotient in
external RAM location 7CH and the remainder in in external RAM location 7DH.
Trending now
This is a popular solution!
Step by step
Solved in 2 steps