Instruction type ORA R in 8085 Microprocessor

Microprocessor8085

In 8085 Instruction set, ORA is a mnemonic, which stands for “OR Accumulator” and “R” stands for any of the following registers, or memory location M pointed by HL pair.

R = A, B, C, D, E, H, L, or M

This instruction is used to OR contents of R with the Accumulator. The result of OR operation will be stored back in the Accumulator. As R can have any of the eight values, there are eight opcodes for this type of instruction. It occupies only 1-Byte in memory.

Mnemonics, Operand Opcode(in HEX) Bytes
ORA A B7 1
ORA B B0 1
ORA C B1 1
ORA D B2 1
ORA E B3 1
ORA H B4 1
ORA L B5 1
ORA M B6 1

Let us consider the instruction ORA E as an example instruction of this category. As it is a 1-Byte instruction so it will occupy a single Byte in the memory. Let us consider that the initial contents of Accumulator and E register are ABH and CDH. The result of execution of this instruction has been shown in the following tracing table.

Before After

(E)

CDH CDH

(A)

ABH EFH

(F)

Any values Cy=0,AC=0,S=1,P=0,Z=0

The internal calculation has been done as shown below −

(A) ABH ---> 1010 1011
(E) CDH ---> 1100 1101
            ---------
        ORA E ---> 1110 1111 (EFH)

Address Hex Codes Mnemonic Comment
2004 B3 ORA E A = A OR E

The timing diagram against this instruction ORA E execution is as follows −

ORA E

Summary − So this instruction ORA E requires 1-Byte, 1-Machine Cycle (Opcode Fetch) and 4 T-States for execution as shown in the timing diagram.

raja
Updated on 30-Jul-2019 22:30:23

Advertisements