Você está na página 1de 5

Addressing Modes in 8085

The method by which the address of source of data or the address of destination of result is
given in the instruction is called Addressing Modes.
The term addressing mode refers to the way in which the operand of the instruction is
specified.
The way by which the microprocessor identifies the operands for a particular instruction is
known as Addressing mode.
Types of Addressing Modes
The process of identifying the operands for a particular instruction can be carried out in several
ways. The various types of addressing modes are as shown below.
Immediate addressing mode
Direct addressing mode
Register addressing mode
Register indirect addressing mode
Implicit addressing mode
1: Immediate Addressing Mode:
An immediate data is transferred directly to the register.
For example.
Consider this instruction
Eg: - MVI A, 30 !"# $ is copied into the register A%
A!I 3" # This instruction adds the immediate data& "'$ to the accumulator.
"'$ is the data here. $ represents $exadecimal value and the immediate value is added to the
accumulator. In this case "'$ is added to the accumulator. (uppose if accumulator has a value
)$ and when this instruction is executed& "'$ is added to the )$ and the result is stored in
accumulator.
In the above instruction the operand is specified within instruction itself.
$: !ire%t Addressing Mode:
In this mode of addressing& the address of the data !operand% is specified within the instruction.
There is a slight difference between the direct addressing modes and immediate addressing
modes. In immediate addressing mode the data itself is specified within instruction& but in direct
addressing mode the address of the data is specified in the instruction.
E&amp'e:
*+T ,#$
-DA ',##$
8 34
Accumulato
r
data
30
Accumulato
r
data
(TA .###$
Consider the instruction (TA .###$
/hen this instruction is executed& the contents of the accumulator are stored in the memory
location specified. In the above example the contents of accumulator are stored in memory
location .###$.
.##0$
.##' $
.##"$
.##.$
.##,$
.# .###$
3: (egister Addressing Mode:
In this type of addressing mode the instruction specifies the name of the register in which the
data is available and *pcode specifies the name !or% address of the register on which the
operation would be performed.
E&amp'e:
1*2 A& 3
$ere the *pcode is 1*2. If the above instruction is executed& the contents of Register 3 are
moved to the Register A& which is nothing but the accumulator.
*ther examples
A4A 3
*n executing the above instruction the contents of Register 3 or logically A4Ded with contents
of register A !accumulator%.
(+3 $
If we execute the above instruction the contents of Register $ will be subtracted from the
contents of the accumulator.
": (egister Indire%t Addressing Mode:
This is indirect way of addressing. In this mode the instruction specifies the name of the register
in which the address of the data is available.
5xample
1*2 A& 1
(+3 1
DCR 1
20
Accumulat
or
dat
a
Accumulato
r
B
Consider 1*2 A& 1. This instruction will move the contents of memory location& whose
address is in $6- register pair to the accumulator.
1 represents the address present in the $6- register pair. (o when 1*2 A& 1 is executed& the
contents of the address specified in $6- register pair are moved to accumulator.
.##0$
.##' $
.##"$
.##.$
.##,$
.0 .###$
5: Imp'i%it Addressing Mode:
There are certain instructions in )#)0 which does not re7uire the address of the operand to
perform the operation. They operate only upon the contents of accumulator. This mode doesn8t
re7uire any operand
E&amp'e:
C1A
RA-
RAR
C1A complements the contents of accumulator.
If RA- is executed the contents of accumulator is rotated left one bit through carry.
If RAR is executed the contents of accumulator is rotated right one bit through carry.
25
L
00 20
Accumulat
or
H