Uploaded by LUCAS JAPHET

class exercise

advertisement
CLASS EXERCISE
1.Write instructions to load the hexadecimal
numbers 65H in register C, and 92H in the
accumulator. Display the number 65H at
PORT0 and 92H at PORT1?
2. If the 8085 adds 87H and 79H, specify the
contents of the accumulator and the status
of the S, Z, and CY flag?
CLASS EXERCISE…
3. Write an assembly program to add two bit
numbers 7H and 8H and store the output at
memory location 7200H.
4. Load the number 5CH in register D . Load
the number 9E H in register C . Increment
the Contents of register C by one. Add the
contents of register C and D and Display the
sum at output port1.
CLASS EXERCISE…
5.Write the three instructions that clear the
accumulator.
6 i) Load 48H, F3H, 76H, and 40H into
registers A, B, C and H respectively
• ii) transfer the contents of register B into
register L
• iii) store the contents of Register A into
memory location with address 3001H
CLASS EXERCISE…
7. Specify the contents of the registers and
the flag status as the following instructions
are executed
A BC D S Z CY
MVI A, 00H
MVI B, F8H
MOV C, A
MOV D, B
HLT
• 8. Write an instruction which read the input data
from PORT 08H and store in register B. Subtract 92H
10. Write a program using the ADI instruction to add
the hexadecimal numbers 3AH and 48H and display
the answer at an output PORT 01H.
11. Specify the contents of registers and the flag
status (S, Z, CY) after the instruction ORA A is executed
• MVI A, A9H
• MVI B, 57H
• ADD B
• ORA A
Download