Instruction Formats: Each Instruction Consists of Two Parts
Instruction Formats: Each Instruction Consists of Two Parts
Instruction Formats: Each Instruction Consists of Two Parts
Operand : specifies the data or provides the data . It can be 8 bit or 16 bit.
1/30/2013 1
MOHIT VERMA
Length of Instructions
3 - byte instruction 2- byte instruction 1-byte instruction
MOHIT VERMA
1/30/2013
3- Byte instruction
First byte: specifies the opcode 2nd byte :specifies the operand 3rd byte : specifies the operand
Opcode Operand (lower order 8 bit) Operand (higher order 8 bit)
These instructions use to specify the 16 bit data or memory address. Example: STA 3000H Move the contents of Accumulator to 3000H memory
MOHIT VERMA
1/30/2013
2- Byte instruction
First byte: specifies the opcode 2nd byte :specifies the operand
Opcode Operand
These instructions used to specify 8 bit data or I/O port address. Example: MVI B, 57H Move the data 57H to register B.
MOHIT VERMA
1/30/2013
1- Byte instruction
1 byte instruction includes the opcode and operand in the 8 bit only .
Opcode
These instructions do not specify 8 bit /16 bit data/address explicitly. Example: MOV B,C Move the content of C register to B register.
MOHIT VERMA
1/30/2013
To perform any operation, we have to give the corresponding instructions to the microprocessor. In each instruction, programmer has to specify 3 things:
Operation to be performed.
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.
MOHIT VERMA
1/30/2013
MOHIT VERMA
1/30/2013
In this mode, the address of the operand is given in the instruction itself.
LDA is the operation. 2500 H is the address of source. Accumulator is the destination.
10
MOV A, B
MOHIT VERMA
11
MOV A, M Move data from memory location specified by H-L pair to accumulator.
MOV is the operation. M is the memory location specified by H-L register pair. A is the destination.
1/30/2013
MOHIT VERMA
12
MVI A, 05 H
MOHIT VERMA
13
If address of source of data as well as address of destination of result is fixed, then there is no need to give any operand along with the instruction.
Complement accumulator.
CMA
14
Review Questions ?
Q-1) Explain the classification of the instruction sets of 8085. Q-2) Explain the instruction sets of 8085 on the basis of the length of instructions . Q-3) Define & Explain various Addressing modes of 8085 with two example each. AND SO ON ..
MOHIT VERMA
1/30/2013
15