Home  >  Article  >  What are the basic functions of the controller

What are the basic functions of the controller

王林
王林Original
2021-01-25 14:46:0964438browse

The basic function of the controller is to control the various parts of the machine to work in harmony. The controller is the nerve center of the computer, directing all components in the machine to work in automated coordination. The main components inside the controller are instruction registers, decoders, timing beat generators, operation control components and instruction counters.

What are the basic functions of the controller

#The operating environment of this article: windows10 system, thinkpad t480 computer.

What is a controller

The computer controller is the nerve center of the computer, directing all components in the machine to automatically coordinate their work. Under the control of the controller, the computer can automatically perform a series of operations according to the steps set by the program to complete specific tasks.

Functions of the controller

1. Sequencing. The instructions that make up the program must be executed in a certain order and cannot be messed up.

2. Timing. An electronic computer is a complex machine, composed of numerous components and parts, and different signals follow different paths. In order for these elements and components to work in harmony, the system must have a unified time standard - clock and beat. The clock and beat in a computer are provided by an oscillator. The operating frequency of the oscillator is called the clock frequency. Obviously, the higher the clock frequency, the faster the computer will work.

The combination of sequencing and timing is called timing sequence.

3. Operation control. The controller should be able to send operation control signals to relevant components at the specified beat according to the content specified in the instruction.

What are the basic functions of the controller

Main components inside the controller:

1. Instruction register: stores the data obtained from the memory instruction.

2. Decoder: Translate the operation code in the instruction into a control signal.

3. Timing beat generator: generates timing pulse beat signals to make the computer work rhythmically and orderly.

4. Operation control components: combine control signals to control each component to complete corresponding operations.

5. Instruction counter: Calculate and point out the address of the next instruction.

Working process of the controller

1. Fetch instructions. The address of the current instruction is stored in the program counter (PC) of the controller. The first step in executing an instruction is to send the address to the memory's address driver (not shown), fetch the instruction according to the address, and send it to the instruction register (Instruction Register, IR). at the same time. PC automatically adds 1. Get ready to take the next order.

2. Analysis instructions. An instruction consists of two parts: one part is called the operation code (OP). Indicates what operation the instruction is to perform; the other part is called the data address code, which is used to indicate which address the data stored in is to be operated on. In the instruction analysis stage, the data address code must be sent to the memory to retrieve the required operands to the arithmetic unit. At the same time, the OP is sent to the instruction decoding component, which is translated into signals for which operations are to be performed on which components, and then the specified signals (and timing signals) are sent to the specified components through the operation control logic.

3. Send operation control signals. The relevant operation control signals are sent to the relevant components according to the timing arrangement, so that the relevant components can complete the specified operations in the specified beat.

(Learning video sharing: Introduction to Programming)

The above is the detailed content of What are the basic functions of the controller. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn