Register codes of 8085 Microprocessor

MicrocontrollerMicroprocessor8085

Using 16-bit address, 8085 can access one of the 216= 64K locations. As a single hexadecimal digit can be expressed in4-bit notation so, in 8085, memory address can be expressed using four hexadecimal digits. Similarly, for convenience, we can represent all 8085 CPU registers as A, B, C etc. using binary notations. Internally 8085 specifies these registers using 0s and 1s only. So3-bits are just enough to represent a register. The 3-bit register codes for the registers of 8085 are shown in the following table

With 3-bit register code, eight registers can be specified in maximum as 23= 8. On the other hand, 8085 has only seven registers. So note that registration code 110 does not specify any register.

Register
Register code
B
000
C
001
D
010
E
011
H
100
L
101
M
110
A
111

Fig − Three-bit register codes for 8085 registers

Using these binary codes, hex-codes against mnemonics are formed. For example:

  • The opcode for MOV E, H −  To represent MOV we are having 2-bits 0 1 and rest 6-bits to represent 2registers destination and source against 3-bits each. i.e.
    01  r1 code  r2 code
    So MOV E, H will have the hex-code as 0 1  0 1 1  1 0 0 => 5CH

  • The opcode for MOV A, B −  To represent MOV we are having 2-bits 0 1 and rest 6-bits to represent 2registers destination and source against 3-bits each. i.e.
    01  r1 code  r2 code
    So MOV A, B will have the hex-code as 0 1  1 1 1  0 0 0 => 78H

  • The opcode for MOV E, M −  To represent MOV we are having 2-bits 0 1 and rest 6-bits to represent 2registers destination and source against 3-bits each. i.e.
    01  r1 code  r2 code
    So MOV E, M will have the hex-code as 0 1  0 1 1  1 1 0 => 5EH

  • The opcode for MVI E, data −  To represent MVI we are having 2-bits 0 0 and rest 6-bits to represent1 register destination and another 110-bit combination to denote itis memory related operation as to read the data from the memory.i.e.
    00  r1 code  1 1 0
    So MOV E, M will have the hex-code as 0 0  0 1 1  1 1 0 => 1EH

raja
Published on 04-Jan-2019 17:17:32
Advertisements