In this post, we will discuss Instruction Cycle and Machine Cycle in the 8085 Microprocessor. In this process, we will go through questions and answers related to the Fetch Cycle, Instruction Cycle, Machine Cycle & T-state of 8085.
We know that the microprocessor is called a sequential machine because it performs the jobs in a sequential manner, one after the other. It is designed to fetch the instruction pointed to by the program counter, and then decode and execute the instruction within the processor. If necessary, further operand fetch takes place before completing the execution.
To execute a program, the 8085 performs various operations such as opcode fetch, operand fetch, and memory read/write or I/O read/write.
- Define Opcode and Operand with examples
- Define Instruction Cycle
- Define Machine Cycle
- Define T-state
- Indicate the different machine cycles of 8085
- Why a microprocessor based system is called a sequential machine?
- Explain a typical fetch cycle (FC) of a microprocessor
- Explain the instruction cycle of a microprocessor
- Related Posts (8085 based)
Define Opcode and Operand with examples
In a microprocessor, each instruction has two parts – operation code (known as an opcode) and operand.
Opcode: Opcode is a command such as ADD which means addition.
Operand: Operand is an object to be operated on, such as a byte or the contents of a register.
Example of Opcode and Operand:
Define Instruction Cycle
The instruction cycle is the time taken by the processor to complete the execution of an instruction. An instruction cycle consists of one to six machine cycles.
Define Machine Cycle
Machine Cycle is the time required to complete one operation-accessing either the memory or an I/O device. A machine cycle consists of three to six T-states.
T-state is the time corresponding to one clock period. The T-state is the basic unit used to calculate the time taken for the execution of instructions and programs in a processor.
Indicate the different machine cycles of 8085
Every instruction of the 8085 requires a definite number of machine cycles.
8085 has seven different machine cycles. These are:
- Opcode Fetch
- Memory Read
- Memory Write
- I/O Read
- I/O Write
- Interrupt Acknowledge
- Bus Idle.
Why a microprocessor based system is called a sequential machine?
A microprocessor-based system can perform the jobs in a sequential manner, one after the other. That is why it is called a sequential machine.
Explain a typical fetch cycle (FC) of a microprocessor
The time required to fetch an opcode (operation code) from a memory location is called Fetch Cycle (FC).
A typical FC may consist of 3T states.
In the first T-state (T1), the memory address, residing in the PC(program counter), is sent to the memory.
The content of the addressed memory (i.e., the opcode residing in that memory location) is read in the second T-state (T2).
In the third T-state(T3) this opcode is sent via the data bus (DB) to the instruction register (IR).
For slow memories, it may take more time in which case the processor goes into ‘wait cycles’. Most microprocessors have the provision of wait cycles to cope with slow memories.
A typical FC may look like the following:
Explain the instruction cycle of a microprocessor
When a processor executes a program, the instructions (1 or 2 or 3 bytes in length) are executed sequentially by the system. The time taken by the processor to complete one instruction is called the Instruction Cycle (IC).
An IC consists of Fetch Cycle (FC) and an Execute Cycle (EC). Thus IC = FC + EC. It is shown in Figure 2. Depending on the type of instruction, IC time varies.
Author of this post
This post is co-authored by Professor Saraswati Saha, who is an assistant professor at RCCIIT, a renowned degree engineering college in India. Professor Saha teaches subjects related to digital electronics & microprocessors.
Related Posts (8085 based)
FAQs on addressing modes of instructions | execution of an instruction in 8085 microprocessor
Arithmetic Instructions in 8085 Microprocessor for Arithmetic operations: Revision notes
8085 Microprocessor – tutorials (hub)
Microprocessor class notes – PDF download