Instruction Set of 8085 MCQ Quiz in தமிழ் - Objective Question with Answer for Instruction Set of 8085 - இலவச PDF ஐப் பதிவிறக்கவும்
Last updated on Mar 12, 2025
Latest Instruction Set of 8085 MCQ Objective Questions
Top Instruction Set of 8085 MCQ Objective Questions
Instruction Set of 8085 Question 1:
Calculate the time required to execute the entire instruction cycle if two machine codes, 0011 1110 and 0011 0010, are stored in memory locations 2000H and 2001H, respectively.
If the clock frequency is 2 MHz, the first machine code represents opcode to load data byte in the accumulator and the second code represents data to be loaded in the accumulator.
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 1 Detailed Solution
Explanation:
Here two machine codes are being executed:
1. Opcode Fetch
2. Data to be uploaded in the accumulator
We can use the following instruction set:
MVI A, data
1 This is a 2-byte instruction.
2 Immediate addressing mode is used.
3 Total machine cycle = Opcode Fetch + Memory Read
4 Total machine cycle = 4T + 3T = 7T
Where T = T-states.
Calculation:
f = 2 MHz
\(T=\frac{1}{f}=\frac{1}{2}=0.5 \ μ s\)
Total machine cycle = 7T
Total machine cycle = 7 × 0.5 = 3.5 μs
Instruction Set of 8085 Question 2:
How is the status of the carry, auxiliary carry and parity flag affected if write instruction?
MOV A#9C
ADD A, #64HAnswer (Detailed Solution Below)
Instruction Set of 8085 Question 2 Detailed Solution
Concept:
For 8051 Microcontroller.
\(CY = \left\{ {\begin{array}{*{20}{c}} {0\;\left[ {When\;no\;carry\;from\;MSB\;i.e.\;{D_7}} \right]}\\ {1\;\left[ {When\;carry\;from\;MSB\;i.e.\;{D_7}} \right]} \end{array}} \right.\)
\(AC = \left\{ {\begin{array}{*{20}{c}} {0\;\left[ {When\;no\;carry\;from\;{D_3}\;to\;{D_4}} \right]}\\ {1\;\left[ {When\;carry\;from\;{D_3}\;to\;{D_4}} \right]} \end{array}} \right.\)
\(P = \left\{ {\begin{array}{*{20}{c}} {1\;\left[ {When\;odd\;no.\;of\;1's\;present} \right]}\\ {0\;\left[ {When\;even\;no.\;of\;1's \; present} \right]} \end{array}} \right.\)
Explanation:
Instruction 1: MOV A#9C
This instruction moves the immediate value 9C into the accumulator (A). The binary representation of 9C is 1001 1100.
After executing this instruction, the status of the flags remains unchanged, as the MOV instruction does not affect the flags.
Instruction 2: ADD A, #64H
This instruction adds the immediate value 64H to the accumulator (A). The binary representation of 64H is 0110 0100.
To perform the addition, we start from the least significant bit (LSB) and move towards the most significant bit (MSB), considering the carry from each bit addition.
Adding the LSB (0 + 0), we get:
Carry = 0
Result = 0
Adding the next bit (0 + 1), we get:
Carry = 0
Result = 1
Adding the next bit (1 + 0), we get:
Carry = 0
Result = 1
Adding the next bit (1 + 0), we get:
Carry = 0
Result = 1
Adding the next bit (1 + 1), we get:
Carry = 1
Result = 0
Adding the next bit (1 + 0), we get:
Carry = 1
Result = 1
Adding the next bit (0 + 1), we get:
Carry = 1
Result = 0
Adding the most significant bit (0 + 1), we get:
Carry = 1
Result = 1
After performing the addition, the carry (CY) flag is set to 1, indicating a carry-out from the MSB. The auxiliary carry (AC) flag is set to 1, as there is a carry from bit 3 to bit 4. The parity (P) flag is set to 1, as the result has an even number of set bits (1s).
Therefore, the correct option is:
4) CY = 1, AC = 1, P = 1
Instruction Set of 8085 Question 3:
With reference to 8085 microprocessor, which of the following statements are correct?
1. INR is 1-byte instruction
2. OUT is 2-byte instruction
3. STA is 3-byte instruction
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 3 Detailed Solution
- INR is a 1-byte instruction as it requires 1-Byte, 3-Machine Cycles (Opcode Fetch, Memory Read, Memory Write) and 10 T-States.
- OUT is a 2-byte instruction as it requires 2-Bytes, 3-Machine Cycles (Opcode Fetch, Memory Read, I/O Write) and 10 T-States.
- STA is a 2-byte instruction requires 3-Bytes, 4-Machine Cycles (Opcode Fetch, Memory Read, Memory Read, Memory Write) and 13 T-States.
Instruction Set of 8085 Question 4:
In 8085 microprocessor, assume that the stack pointer is pointing to the memory location 2000H and register DE contains value 1050H. After the execution of instruction PUSH D, the stack pointer would be pointing at:
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 4 Detailed Solution
Stack pointer
A stack pointer is a small register that stores the memory address of the last data element added to the stack or, in some cases, the first available address in the stack.
PUSH Command
Push operation refers to inserting an element in the stack. Since there's only one position at which the new element can be inserted into the top of the stack, the new element is inserted at the top of the stack.
Explanation:
It is given that the stack pointer is pointing to the memory location 2000H.
This means that 2000H is the memory location that is at the top of the stack.
After the execution of instruction PUSH D, a new element is inserted at the top of the stack. In this element, the data 1050H will be stored.
The memory address of the newly added element is given by 2000H + 0001H.
2000 H = 0010 0000 0000 0000
0001 H = 0000 0000 0000 0001
2000H + 0001H = 0001 1111 1111 1111
0001 1111 1111 1111 = 1FFEH
The stack pointer would be pointing at the memory address 1FFEH
Instruction Set of 8085 Question 5:
In an 8085 microprocessor the following instructions are run
MVI B, 00 H
MVI A, 1C H
DCR B
DAA
STA TEMP
HLT
The contents of TEMP location after execution of above program isAnswer (Detailed Solution Below)
Instruction Set of 8085 Question 5 Detailed Solution
The following instructions are run
MVI B, 00 H; moves 00 H to register B ⇒ B = 00 H
MVIA, 1CH; moves 1CH to register A ⇒ A = 1CH
DCR B; Decrements the contents of B (i.e. 00 H) by one. So B = FFH
DAA; DAA instruction changes the binary values of contents of the accumulator to BCD.
I. If the value of the lower four bits in the accumulator is greater than 9 or if the AC flag is set, the instruction adds 0110 to the lower four bits
II. If the value of the higher four bits in the accumulator is greater than 9 or if cy flag is set, the instruction adds 0110 to higher-order 4-bits.
A = 1CH = 0001 1100, the lower order bits are greater than 9, therefore DAA adds 0110 to lower bits to adjust the binary result to BCD.
\({\rm{A}}:1{\rm{\;CH}} = \begin{array}{*{20}{c}} {\underline {\begin{array}{*{20}{c}} {0001}&{1100}\\ {}&{0110} \end{array}} }\\ {\begin{array}{*{20}{c}} {0010}&{0010} \end{array}} \end{array}\)
So, A = 22 H
STA TEMP; Stores the contents of the accumulator at memory location TEMP
∴ Contents of TEMP are 22 HInstruction Set of 8085 Question 6:
In 8085A microprocessor, the operation performed by the instruction LHLD 2100H is
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 6 Detailed Solution
For the 8085A microprocessor, given instruction is LHLD 2100H
This operation load registers L and H with the content in the memory at location 2100H and 2101H respectively
i.e. (H) ← M (2101H) & (L) ← M (2100H)
where L is lower address data and H is higher address data.
Instruction Set of 8085 Question 7:
The number of memory cycles required to execute the following 8085 instructions
(i) LDA 3000 H
(ii) LXI D, F0F1 H
Would be-Answer (Detailed Solution Below)
Instruction Set of 8085 Question 7 Detailed Solution
LDA 3000H → Fetch, Read, Read, Read (4 memory cycles)
LXI D, F0F1H → Fetch, Read, Read (3 memory cycles)
Instruction Set of 8085 Question 8:
What is the number of machine cycles in the instruction LDA 2000 H that consist of thirteen states?___
Answer (Detailed Solution Below) 4.00
Instruction Set of 8085 Question 8 Detailed Solution
LDA 2000 H
⇒ 3 B instruction
⇒ OPFC + OPRC + OP2RC + MRC
⇒ 4 machine cycles
⇒ 4T + 3T + 3T + 3T
⇒ 13 T
Instruction Set of 8085 Question 9:
In the following 8085 program how many times (decimal) is the DCR C executed?
MVI C, 78 H
LOOP: DCR C
JNZ LOOP
HLT
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 9 Detailed Solution
LOOP: MVI C, 78 H; Moves 78 H to register C. So, C = 78 H
DCR C; Decreases the contents of C by 1.
JNZ LOOP; Jumps at LOOP if zero flag is not set.
HLT; Halts the execution of the program
The execution of the program remains in LOOP till the zero flag is set. The zero flag is set when the contents of C becomes zero. During each iteration of the loop, the contents of C are reduced by one. The initial contents of C are 78 H. The decimal equivalent of 78 H is 120. So, the loop is executed 120 times.Instruction Set of 8085 Question 10:
Consider the following instructions of 8085 microprocessor.
1. MOV M, A
2. SUB C
3. MVI A, E2
4. CMP B
Which of these cause change in the status of flags?
Answer (Detailed Solution Below)
Instruction Set of 8085 Question 10 Detailed Solution
Concept:
Data transfer operations do not affect the status of flags.
Application:
MOV and MVI are data transfer instructions, they do not affect any flag.
SUB and CMP are arithmetic and Logical instructions that are executed in ALU and hence they do affect flags.