Upload
heta-desai
View
212
Download
0
Embed Size (px)
Citation preview
7/25/2019 IC_UNIT 2_2
1/10
ADDRESSING MODES
HETA J DESAI
SDJINTERNATIONAL COLLEGE
14/11/2016
FYBCA_ADDRESSINGMODES_ID_SDJIC
7/25/2019 IC_UNIT 2_2
2/10
Addressing Modes
2
To perform any operation, we have togive the corresponding instructions to
the microprocessor.
In each instruction, programmer has to
specify 3 things:
Operation to be performed.
Address of source of data.
Address of destination of result.
4/11/2016FYBCA_ADDRESSING
7/25/2019 IC_UNIT 2_2
3/10
OP CODE The first part of instructionwhich specifies task to be performed is
called op-code
Operand The second part of instruction isthe data to be operated on is called
operands.
First byte is op code rest are operands.
FYBCA_ADDRESSING4/11/2016
3
7/25/2019 IC_UNIT 2_2
4/10
Addressing Modes of 8085
4
The method by which the address ofsource of data or the address of
destination of result is given in the
instruction is called AddressingModes.
Addressing modes are various
technique to specify data for instructions.
4/11/2016FYBCA_ADDRESSING
7/25/2019 IC_UNIT 2_2
5/10
Types of Addressing Modes
5
1. Direct Addressing Mode
2. Register Addressing Mode
3. Register Indirect Addressing Mode
4. Immediate Addressing Mode
5. Implicit Addressing Mode
4/11/2016FYBCA_ADDRESSING
7/25/2019 IC_UNIT 2_2
6/10
Direct Addressing Mode
In this mode, the address of theoperand is given in the instructionitself.[Memory address is directly
given]
STA is the operation.
2500 H is memory address where data is to be stored It is to be understood that source of data is accumulator
Accumulator is a register for short-term, intermediate storage
of arithmetic and logic data in a computer's CPU (central
processing unit).
STA 2500 H
6
Store content of accumulator
in the memory location 2400H.
4/11/2016FYBCA_ADDRESSING
http://whatis.techtarget.com/definition/registerhttp://searchcio-midmarket.techtarget.com/definition/CPUhttp://searchcio-midmarket.techtarget.com/definition/CPUhttp://whatis.techtarget.com/definition/register7/25/2019 IC_UNIT 2_2
7/10
Register Addressing Mode
In this mode, the operand is in generalpurpose register.
MOV is the operation.
B is the source of data.A is the destination.
MOV A, B
7
Move the contents of register B toA.
4/11/2016FYBCA_ADDRESSING
7/25/2019 IC_UNIT 2_2
8/10
Register Indirect Addressing
Mode In this mode, the address of operand is specified by a register pair.
L11 H,2500 H LOAD H-L PAIR WITH 2500 H.
now next instruction after this is register indirect addressing technique.
MOV is the operation.
M is the memory location specified byH-Lregister pair.
Ais the destination.
The address of memory is not directly given in to instruction. The
address resides in H-L pair. And this has already been given in
earlier instruction.
MOV A, M
8
Move data from memory location
whose address in H-L pair to
accumulator accumulator.
4/11/2016FYBCA_ADDRESSING
7/25/2019 IC_UNIT 2_2
9/10
Immediate Addressing Mode
In this mode, the operand is specifiedwithin the instruction itself.
MVI is the operation.
05 is the immediate data (source).A is the destination.
MVI A, 05
9
Move 05 in register A.
4/11/2016
FYBCA_ADDRESSINGMODES_ID_SDJIC
7/25/2019 IC_UNIT 2_2
10/10
Implicit Addressing Mode
If address of source of data as well asaddress of destination of result is fixed,then there is no need to give anyoperand along with the instruction.
RAL Rotate the content of the accumulator
left by one bit.
RAL is the operation.
A is the source.
A is the destination.
14/11/2016
FYBCA_ADDRESSING