Introduction to the microprocessor

Thursday, 12 April 2012
Posted by Crystal

1.2 What is a microprocessor?
         The microprocessor uses the same type of logic that is used in a digital computer’s central processing unit (CPU). Because it is similar to the CPU and it is constructed with microcircuit (IC) technology. The microprocessor has digital circuit for data handling and computation under program control. (The microprocessor is a data processing unit) Data processing is the microprocessor’s main function. Data processing includes both computation and data handling. Computation is performed by logic circuits that make up what is usually called the arithmetic logic unit (ALU). These logic circuits enable us to use functions that cause data changes. Among these functions are Add, Subtract, AND, OR, XOR, Compare, Increment, and Decrement. The ALU cannot perform any of these functions with out data operation on. In order to process data, the microprocessor must have control logic which tells the microprocessor how to decode and execute the program.
Text Box: Program is a set of instructions for processing the data      

The control logic steps the microprocessors through the stored program steps (instructions) in memory. It calls (fetches) them one at a time. After the instruction is fetched, the microprocessor’s control logic decodes the instruction. Then the control logic carries out (executes) the decoded instruction. Because the instructions are stored in memory, you can change them when you want to.
Review: The microprocessor’s purpose is to process data. To do this, it must have logic to process and handle data, and control logic. The processing logic moves data from place and performs operations on the data.
        Microprocessor is a multipurpose, programmable, clock-driven, register-base, electronic device that reads binary instructions from a storage device called memory, accepts binary data as input and processes data according to those instructions, and provides results as output.







1.2.1   4 components of microprocessor
Text Box: Input 



 


Text Box: Microprocessor


Text Box: Output









Text Box: Memory

-         The physical components of this system are called hardware.
-         A set of instructions written for the microprocessor to perform a task is called a program.
-         A group of programs is called software.
         The microprocessors applications are classified primarily in two categories: reprogrammable systems and embedded systems. In reprogrammable systems, such as microcomputers, the microprocessor is used for computing and data processing, a Personal Computer (PC) is a typical illustration. In an embedded system, the microprocessor is a part of a final product and is not available for reprogramming to the end user.
         The microprocessor operates in binary digits, 0 and 1, also known as bits. Bit is an abbreviation for the term binary digit. These digits are represented in terms of electrical voltages.
         Each microprocessor recognizes and processes a group of bits called the word, and microprocessor are classified according to their word length. The fact that the microprocessor is programmable means it can be instructed to perform given tasks within its capability. The instructions are entered or stored in a storage device called memory, which can be read by the microprocessor.
         Memory is like the pages of a notebook with space for a fixed number of binary numbers on each line.

1.2.2 The microprocessor operations
The microprocessors fetches (gets) an instruction


 


The control logic decodes what the instruction says to do


 


Decoding


 
The microprocessor executes (carries out) the instruction
(Fetch-and-execute cycle, or the fetch/execute cycle)

1.3 Microprocessor Microcomputer
The microprocessor is the heart of many products, but the microprocessor is never a complete, working by itself. It still needs I/O, memory, data storage or program storage and power.
1.3.1 What is a microcomputer?
The words “Microprocessor” and “Microcomputer” are used to mean the same thing, but in fact these words have different meanings. The microprocessor is an IC (data processing and control). The microcomputer is a complete computing system built around a microprocessor.
1.3.2      What is the power of a microprocessor?
Almost all microprocessors are made on silicon die (IC). These ICs are about ¼ inch (in), or 0.64 centimeters (cm), on a side. The power of a microprocessor is its capacity to process data. These are three main measures of the power of a microprocessor: the length of the microprocessor’s data word; the number of memory words that the microprocessor can address; and the speed with which the microprocessor can execute an instruction.

The lengths of microprocessor’s data words are including 4 bits, 8 bits, 16 bits, 32 bits and 64 bits. The 8 bits data word is so common that it has been given the special name byte. Because the byte is so commonly used, 16 bit microprocessors often have instructions that let them process their 16 bits data word in two 8 bit bytes.


Figure: A 16bit digital word showing the high and low byte breakdown
The 4 bit microprocessor was the first one developed. Microprocessors of this word length are still popular in some types of work. Four bits is the length needed for a binary-coded decimal (BCD) numbers. In some applications, including; calculators, simple consumer products and toys, the microprocessor deals only with BCD numbers. The 8 bits word length was the next developed after the 4 bits.
1.3.3 The advantages of 8 bit microprocessor
1.   The 8 bit word length is twice 4 bits.
2.   The 8 bit word length allows two BCD numbers for each CPU data word
3.   The 8 bit word length can hold all the data needed for one character in
American Standard Code for Information Interchange (ASC II), ASCII characters are used widely in data processing to represent numbers, letters, and many special symbols.
         Each time the microprocessor’s word length doubles, the processor becomes more powerful. Greater word lengths have required improved LSI technology. For example, the LSI used to develop some of the new 64 bit microprocessors uses a similar sized chip, but it comes over 23 million transistors.
         Another common measure of microprocessor power is the number of memory bytes that the microprocessor can address. For example, a 4 bit microprocessor stores 4 bit word in memory. The length of the data word is the same as the length of the data word used by the microprocessor. Each word in memory is assigned a location number or address.
Binary Address

Memory contents
(4 bits long)
1111

Data word 15
1110

Data word 14
1101

Data word 13
1100

Data word 12
1011

Data word 11
1010

Data word 10
1001

Data word 9
1000

Data word 8
0111

Data word 7
0110

Data word 6
0101

Data word 5
0100

Data word 4
0011

Data word 3
0010

Data word 2
0001

Data word 1
0000

Data word 0

Figure: A 16bit word memory addressed by a 4bit
         Figure shows the memory-addressing power of single 4 bit word. 4 bits can address 16 words in memory. We number these 16 words from 0 to 15. A single 8 bit word has an address range of 256 memory words. A 16 bit word has an address range of 65,536 memory words. Most microprocessors can use more than a single word to address memory. Therefore the memory address range is not limited by the length of the microprocessor’s data word.
         A shorthand notation is used in specifying the number of bytes. The symbol “K” is used to say “times 1000”. The symbol “M” means “times 1 million”. The symbol “G” means “times 1 billion”.
Data word length
4bit
8bit
16bit
32bit
Memory address range
4096k



8192k




65,536(64k)




32,768(32k)



65,536(64k)



1,048,576(1M)



2,097,152(2M)



4,194,304(4M)




4,294,967,296(4G)



34,359,738,367(32G)

         A third common measure of microprocessor power is the speed with which microprocessor executes an instruction. Speed is determined by the time it takes the microprocessor to complete the fetch / execute cycle for one program step. Some microprocessors are 20 to 100 times faster than others. Each one has oscillator circuit is called the microprocessor’s clock. Slow microprocessors may use a clock that at a few hundred kilohertz (KHz). It takes such a microprocessor 10 to 20 microseconds (ms) to execute one instruction.
  
1.4 Microprocessor-Based System with Bus Architecture

ALU (Arithmetic/Logic Unit) – It performs such arithmetic operations as addition and subtraction, and such logic operations as AND, OR, and XOR. Results are stored either in registers or in memory.
Register Array – It consists of various registers identified by letter such as B, C, D, E, H, L, IX, and IY. These registers are used to store data and addresses temporarily during the execution of a program.
Control Unit – The control unit provides the necessary timing and control signals to all the operations in the microcomputer. It controls the flow of data between the microprocessor and memory and peripherals.
Input – The input section transfers data and instructions in binary from the outside world to the microprocessor. It includes such devices as a keyboard, switches, a scanner, and an analog-to-digital converter.
Output – The output section transfers data from the microprocessor to such output devices as LED, CRT, printer, magnetic tape, or another computer.
Memory – It stores such binary information as instructions and data, and provides that information to the microprocessor. To execute programs, the microprocessor reads instructions and data from memory and performs the computing operations in its ALU section. Results are either transferred to the output section for display or stored in memory for later use.
System bus – It is a communication path between the microprocessor and peripherals. The microprocessor communicates with only one peripheral at a time. The timing is provided by the control unit of the microprocessor.

1.5 Microprocessor Instruction Set and Computer Languages 
         The word (or word length), is the number of bits the microprocessor recognizes and processes at a time. The word length ranges from 4 bits for small microprocessor, to 64 bits for high-end microcomputers.
         The byte is defined as a group of eight bits. The term “nibble”, which stands for a group of four bits, is also found in popular computer magazines and books.

0 comments: