Microprocessors
Total Page:16
File Type:pdf, Size:1020Kb
13 Microprocessors The microprocessor is the heart of a microcomputer system. In fact, it forms the central processing unit of any microcomputer and has been rightly referred to as the computer on a chip. This chapter gives an introduction to microprocessor fundamentals, followed by application-relevant information, such as salient features, pin configuration, internal architecture, instruction set, etc., of popular brands of eight-bit, 16-bit, 32-bit and 64-bit microprocessors from international giants like INTEL, MOTOROLA and ZILOG. 13.1 Introduction to Microprocessors A microprocessor is a programmable device that accepts binary data from an input device, processes the data according to the instructions stored in the memory and provides results as output. In other words, the microprocessor executes the program stored in the memory and transfers data to and from the outside world through I/O ports. Any microprocessor-based system essentially comprises three parts, namely the microprocessor, the memory and peripheral I/O devices. The microprocessor is generally referred to as the heart of the system as it performs all the operations and also controls the rest of the system. The three parts are interconnected by the data bus, the address bus and the control bus (Fig. 13.1). The memory stores the binary instructions and data for the microprocessor. The memory can be classified as the primary or main memory and secondary memory. Read/write memory (R/WM) and read only memory (ROM) are examples of primary memory and are used for executing and storing programs. Magnetic disks and tapes are examples of secondary memory. They are used to store programs and results after the completion of program execution. Microprocessors do not execute programs stored in the secondary memory directly. Instead, they are first copied on to the R/W primary memory. DigitalElectronics:Principles,DevicesandApplicationsAnilK. Maini ©2007JohnWiley&Sons,Ltd. ISBN: 978-0-470-03214-5 526 Digital Electronics Address Bus Memory Microprocessor Data and bus I/O Control Bus Figure 13.1 Microprocessor-based system. Input/output devices are means through which the microprocessor interacts with the outside world. The commonly used input devices include keyboards, A/D converters, switches, cameras, scanners, microphones and so on. LEDs, seven-segment displays, LCD displays, printers and monitors are some of the commonly used output devices. A bus is basically a communication link between the processing unit and the peripheral devices. It is a group of wires that carry information in the form of bits. The address bus is unidirectional and is used by the CPU to send out the address of the memory location to be accessed. It is also used by the CPU to select a particular input or output port. It may consist of 8, 16, 20 or an even greater number of parallel lines. The number of bits in the address bus determines the maximum number of data locations in the memory that can be accessed. A 16-bit address bus, for instance, can access 216 data locations. It is labelled as A0,…,An−1, where n is the width (in bits) of the address bus. The data bus is bidirectional, that is, data flow occurs both to and from the microprocessor and peripherals. Data bus size has a considerable influence on the computer architecture, as parameters such as the word length and the quantum of data that can be manipulated at a time are determined by the size of the data bus. There is an internal data bus, which may not be of the same width as the external data bus that connects the microprocessor to I/O and memory. The size of the internal data bus determines the largest number that can be processed by the microprocessor in a single operation. The largest number that can be processed, for instance, by a microprocessor having a 16-bit internal data bus is 65535. The data bus is labelled as D0,…,Dn−1, where n is the data bus width (in bits). The control bus contains a number of individual lines carrying synchronizing signals. The term ‘bus’ would normally imply a group of lines working in unison. The control bus (if we call it a bus) sends out control signals to memory, I/O ports and other peripheral devices to ensure proper operation. It carries control signals such as memory read, memory write, read input port, write output port, hold, interrupt, etc. For instance, if it is desired to read the contents of a particular memory location, the CPU first sends out the address of that location on the address bus and a ‘memory read’ control signal on the control bus. The memory responds by outputting data stored in the addressed memory location onto the data bus. ‘Interrupt’ tells the CPU that an external device needs to be read or serviced. ‘Hold’ allows a device such as the direct memory access (DMA) controller to take over the address and data buses. Figure 13.2 shows the bus interface between the microprocessor and its peripheral devices. The microprocessor considered in the diagram is an eight-bit microprocessor such as Intel’s 8085. Microprocessor-based systems can be categorized as general-purpose reprogrammable systems and embedded systems. Reprogrammable systems include microcomputers and mainframe and miniframe computers where microprocessors are used for computing and data processing. In embedded systems, they perform a specific task and are not available for reprogramming to the end-user. Examples of these systems include mobile phones, washing machines, microwave ovens, dish washers and so on. Microprocessors 527 Address Bus A15 A0 8085 micro- processor RAM ROM D7 Data Bus D0 Clk —– RD —– WR —–– RES INTR } IO/M Output Input Interface Interface Output Input Device Device Figure 13.2 Bus interface between the microprocessor and its peripheral devices. In most of these systems, the microprocessor, memory and I/O ports are combined onto one chip, known as the microcontroller. Microcontrollers are discussed in detail in Chapter 14. 13.2 Evolution of Microprocessors The evolution of microprocessors has been known to follow Moore’s law, which suggests that the complexity of an integrated circuit, with respect to the minimum component cost, doubles every 24 months. This rule has been generally followed, since the humble beginning of microprocessors as the drivers for calculators to the present-day scenario where every system, from the largest mainframes to the smallest handheld computers, uses a microprocessor at its core. The first microprocessor was introduced in 1971 by the Intel Corporation. It was a four-bit microprocessor, Intel 4004. Other four-bit microprocessors developed were Intel 4040 by Intel, PPS-4 by Rockwell International, T3472 by Toshiba and so on. The first eight-bit microprocessor, named Intel 8008, was also developed by Intel in the year 1972. All these microprocessors were made using PMOS technology. The first microprocessor using NMOS technology was Intel 8080, developed by Intel in the 528 Digital Electronics year 1973. Intel 8080 was followed by Intel 8085 in the year 1975, which became very popular. Other popular eight-bit microprocessors were Zilog’s Z80 (1976) and Z800, Motorola’s MC6800 (1974) and MC6809 (1978), National Semiconductor’s NSC 800, RCA’s 1802 (1976) and so on. The first multichip 16-bit microprocessor was National Semiconductor’s IMP-16, introduced in 1973. The first 16-bit single-chip microprocessor was Texas Instrument’s TMS 9900. Intel’s first 16-bit microprocessor was Intel 8086 introduced in the year 1978. Other 16-bit microprocessors developed by Intel were Intel 80186 (1982), Intel 8088, Intel 80188 and Intel 80286 (1982). Other popular 16-bit microprocessors include Motorola’s 68000 (1979), 68010 and 68012, Zilog’s Z8000, Texas Instruments TMS 9900 series and so on. 32-bit microprocessors came into existence in the 1980s. The world’s first single-chip 32-bit microprocessor was introduced by AT&T Bell Labs in the year 1980. It was named BELLMAC- 32A. The first 32-bit processor introduced by Intel was iapx 432, introduced in 1981. The more popular 32-bit microprocessor was Intel 80386, introduced by Intel in 1985. It was widely used for desktop computers. The 32-bit microprocessor family of Intel includes Intel 486, Pentium, Pentium Pro, Pentium II, Pentium III and Pentium IV. AMD’s K5, K6 and K7, Motorola’s 68020 (1985), 68030 and 68040, National Semiconductor’s 32032 and 32332 and Zilog’s Z80000 are other popular 32-bit microprocessors. All these microprocessors are based on CISC (Complex Instruction Set Computers) architecture. The first commercial RISC (Reduced Instruction Set Computers) design was released by MIPS Technologies, the 32-bit R2000. Some of the popular RISC processors include Intel’s 80860 and 80960, Motorola’s 88100 and Motorola’s, IBM and Apple’s PowerPC series of microprocessors. While 64-bit microprocessor designs have been in use in several markets since the early 1990s, the early 2000s have seen the introduction of 64-bit microchips targeted at the PC market. Some of the popular 64-bit microprocessors are AMD’s AMD64 (2003) and Intel’s x86-64 chips. Popular 64-bit RISC processors include SUN’s ULTRASPARC, PowerPC 620, Intel’s Itanium, MIPS R4000, R5000, R10000 and R12000 and so on. 13.3 Inside a Microprocessor Figure 13.3 shows a simplified typical schematic arrangement of a microprocessor. The figure shown is a generalized one and is not the actual structure of any of the commercially available microprocessors. The important functional blocks include the arithmetic logic unit (ALU), the register file and the control unit. These functional blocks are briefly described in the following paragraphs. Control Control unit bus Register file ALU Internal bus Data bus Figure 13.3 Typical schematic arrangement of a microprocessor.