0% found this document useful (0 votes)
82 views

Lab Manual 5 Semester Experiment No.02 Addressing Modes and Data Transfer Instructions

This lab manual document discusses different addressing modes in microprocessors including: - Register addressing which moves data between registers directly - Immediate addressing which moves a direct number into a register or memory - Register direct addressing which transfers data between a register and memory location stored in the instruction - Register indirect addressing which transfers data between a register and memory using the address in another register It provides examples of each addressing mode and ends with review questions asking the student to write programs demonstrating different addressing modes.

Uploaded by

Arslan Faisal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
82 views

Lab Manual 5 Semester Experiment No.02 Addressing Modes and Data Transfer Instructions

This lab manual document discusses different addressing modes in microprocessors including: - Register addressing which moves data between registers directly - Immediate addressing which moves a direct number into a register or memory - Register direct addressing which transfers data between a register and memory location stored in the instruction - Register indirect addressing which transfers data between a register and memory using the address in another register It provides examples of each addressing mode and ends with review questions asking the student to write programs demonstrating different addressing modes.

Uploaded by

Arslan Faisal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

LAB MANUAL MICOPROCESSOR BASED SYSTEM 5th Semester

(CS-342)
EXPERIMENT NO.02

Addressing Modes and Data Transfer Instructions.

Student Name: Roll No:

Lab Instructor Signatures: Date:

Objectives:
 To know about addressing modes

 Types of modes

 How to use different modes.

 Total Types of addressing modes

Introduction:
Register Addressing:
In this type of addressing we move data from one register to another register directly. Like as MOV
AX, BX
In this example data is moving from ‘BX’ to ‘AX’ Ax is called destination and BX is called Source. In
this source and destination both are register so this is called Register Addressing.
Immediate Addressing:
In this type of addressing Destination can be a register or any other memory but Source will be a direct
number (Data) Like As MOV CX, 50h In this example a number 50H is moving into CX directly.
Register Direct Addressing:
This type transfers a byte or a word between a memory location memory location and a register. The
memory address of the data is stored with the instruction (e.g., MOV AX, List takes 16 bit contents of
the memory address List and moves them into register AX).
Register Indirect Addressing:
In this type of addressing we transfer a byte or a word between a register and a memory location
addressed by a register (e.g., MOV AX, [BX] moves the 16 bits contents of the memory location
addressed by the BX register into register AX).
Base plus Index Addressing:
This is also type of addressing a byte or a word between a register and the memory location indicated
by the sum of a base register and an index register (e.g., MOV AX, [BX+SI] moves the 16 bits
contents of the address indexed by the sum of BX+SI into register AX).

Department of Computer Systems Engineering 1


LAB MANUAL MICOPROCESSOR BASED SYSTEM 5th Semester
(CS-342)
EXPERIMENT NO.02

Addressing Modes and Data Transfer Instructions.


Register relative:
It transfer a byte or a word between a register and the memory location addressed by a register and a
displacement (e.g., MOV AX, [BX+4] or MOV AX, Array[SI]. The first instruction transfers the 16
bits contents of the memory location indexed by the BX+4 into the AX register.
Base Plus relative index register:
It uses to transfer a byte or a word between a register and the memory location addressed by a base
register and an index register plus a displacement (e.g., MOV AX, Array [BX+DI] or MOV AX,
[BX+DI+4]). The first example address the memory location indexed is the Array +BX+DI and transfer
a 16 bit number from that memory location into register AX. The second example uses the address
generated by the addition BX+DI+4.

Example 1: Program to verify register and immediate addressing modes

Department of Computer Systems Engineering 2


LAB MANUAL MICOPROCESSOR BASED SYSTEM 5th Semester
(CS-342)
EXPERIMENT NO.02

Addressing Modes and Data Transfer Instructions.

REVIEW QUESTIONS

Question 1: Write a program that stores any two hex numbers in memory and transfer them to any two
registers.

Question 2: Write a short program using modes that address information in data segment.
(Hint: allocate memory location in the data segment using DB and DW directive)

Department of Computer Systems Engineering 3

You might also like