![]() |
VOOZH | about |
Microprocessors are electronic devices that process digital information using instructions stored in memory. Machine control instructions are a type of instruction that control machine functions such as Halt, Interrupt, or do nothing. These instructions alter the different type of operations executed in the processor. In this article, we will discuss the various types of machine control instructions found in microprocessors and their significance in controlling the microprocessor's operations.
1. NOP (No operation)
2. HLT (Halt)
3. DI (Disable interrupts)
4. EI (Enable interrupts)
5. SIM (Set interrupt mask)
6. RIM (Reset interrupt mask)
1. NOP (No operation)
Opcode- 00
Operand- None
Length- 1 byte
M-Cycles- 1
T-states- 4
Hex code- 00
NOP is used when no operation is performed. It is commonly used to fill in time delay or to delete and insert instructions while troubleshooting. During the execution of NOP, no flags are affected.
2. HLT (Halt)
Opcode- 76
Operand- None
Length- 1 byte
M-Cycles- 2 or more
T-states- 5 or more
Hex code- 76
HLT is used to stop the execution of the program temporarily. The microprocessor finishes executing the current instruction and halts any further execution. The contents of the registers are unaffected during the HLT state. HLT can be used to enter a wait state in which the microprocessor waits for a specific event to occur before resuming execution.
3. DI (Disable interrupts)
Opcode- F3
Operand- None
Length- 1 byte
M-Cycles- 1
T-states- 4
Hex code- F3
DI is used when the execution of a code sequence cannot be interrupted. For example, in critical time delays, this instruction is used at the beginning of the code and the interrupts are enabled at the end of the code. The TRAP interrupt cannot be disabled.
4. EI (Enable interrupts)
Opcode- FB
Operand- None
Length- 1 byte
M-Cycles- 1
T-states- 4
Hex code- FB
EI is used to enable interrupts after a system reset or the acknowledgement of an interrupt. The Interrupt Enable flip-flop is reset, thus disabling the interrupts.
5. SIM (Set interrupt mask)
Opcode- 30
Operand- None
Length- 1 byte
M-Cycles- 1
T-states- 4
Hex code- 30
SIM is used for the implementation of different interrupts of 8085 microprocessor like RST 7.5, 6.5, and 5.5 and also serial data output. It does not affect the TRAP interrupt.
6. RIM (Reset interrupt mask)
Opcode- 20
Operand- None
Length- 1 byte
M-Cycles- 1
T-states- 4
Hex code- 20
RIM is a multipurpose instruction used to read the status of 8085 interrupts 7.5, 6.5, 5.5, and to read serial data input bit.
Machine control instructions are used in a variety of applications, including embedded systems, control systems and industrial automation.