Date post: | 23-Dec-2015 |
Category: |
Documents |
Upload: | bennett-mathews |
View: | 227 times |
Download: | 0 times |
Chapter 17
Microprocessor Fundamentals
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Microprocessor– general-purpose device– driven by software– perform a specific task
• Support Circuitry– data input switches– output data
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Microprocessor– Intel 8085– Motorola 6800– Zilog Z80– reads program instructions– executes instructions drives external buses– to make connected devices perform functions
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Microprocessor– buses
• groups of conductors
• routed throughout the system
• tapped into by various devices
• share information
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Address Bus– 16 bits wide– generated by microprocessor– to select a particular location or IC to be active
• Data Bus– sends or receives 8 bits of data to or from the
address– bidirectional
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Control Bus– varying width depending on processor used– carries control signals– identifies operation
• Address Decoder– like 74LS138– ensures that only one IC is active– to avoid bus conflict
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Memory– ROM or EPROM
• initialization instructions
• monitor program
• operating system
– RAM• volatile
• used only for temporary storage
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Introduction to System Components and Buses
• Input Port– provide data to microprocessor via the data bus– octal buffer with tri-state outputs
• Output Port– talk to the outside world– sends data to output device– octal D flip-flop
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Software Control of Microprocessor Systems
• Operational changes made with software
• Accumulator– stores information for the microprocessor
• Assembly Language– software that drives the microprocessor– mnemonics
• abbreviation of the operation to be performed
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Internal Architecture of a Microprocessor
• 8085A software compatible with 8080A
• See Figure 17-2– internal architecture– functional block diagram
• See Figure 17-3– pin configuration
• Central Processing Unit (CPU)
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Figure 17-2
Figure 17-3
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Internal Architecture of a Microprocessor
• Internal Data Bus
• General-Purpose Registers– B, C, D, E, H, L
• Arithmetic Logic Unit (ALU)– arithmetic operations– five flag flip-flops
• Instruction Register and Decoder– receive instructions interpret and create signals
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Internal Architecture of a Microprocessor
• Interrupt Control– external digital signal that interrupts the
software during execution
• Stack Pointer– stores address of the last entry on the stack– stack - data storage area in RAM
• Program Counter– 16-bit address of next software instruction
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Instruction Execution Within a Microprocessor
• See Figure 17-4
• Load Accumulator
• Store Accumulator
• See Table 17-2– assembly language and machine code listing
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Figure 17-4
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Hardware Requirements for Basic I/O Programming
• Memory-Mapped I/O– input and output devices accessed as if they
were memory locations
• I/O-Mapped I/O– identify input and output devices by an 8-bit
port number
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Writing Assembly Language and Machine Language Programs
• Assembler– translates mnemonic into hexadecimal machine
code and stores in memory address
• Compiler– High-level languages
• Pascal, FORTRAN, C++, BASIC
– get reduced to machine language before execution
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Writing Assembly Language and Machine Language Programs
• Assembly language translates directly to machine code
• See Table 17-3– program in three languages– opcodes
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Survey of Microprocessors and Manufacturers
• See Table 17-4
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Summary
• A system designer should consider using a microprocessor instead of logic circuitry whenever an application involves making calculations, making decisions based on external stimuli, and maintaining memory of past events.
• A microprocessor is the heart of a computer system. It reads and acts on program instructions given to it by a programmer
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Summary
• A microprocessor system has three buses: address, data, control.
• Microprocessors operate on instructions given to them in the form of machine code (1’s and 0’s). The machine code is generated by a higher-level language like C or assembly language.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Summary
• The Intel 8085A is an 8-bit microprocessor. It has 7 internal registers, an 8-bit data bus, an arithmetic/logic unit, and several input/output functions.
• Program instructions are executed inside the microprocessor by the instruction decoder, which issues the machine cycle timing and initiates input/output operations.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Summary
• The microprocessor provides the appropriate logic levels on the data and address buses and takes care of the timing of all control signals output to the connected interface circuitry.
• Assembly language instructions are written using mnemonic abbreviations and then converted into machine language so that they can be interpreted by the microprocessor.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.
Summary
• Higher-level languages like C or Pascal are easier to write than assembly language, but they are not as memory efficient or as fast. All languages must be converted into a machine language matching that of the microprocessor before they can be executed.
William KleitzDigital Electronics with VHDL, Quartus® II Version
Copyright ©2006 by Pearson Education, Inc.Upper Saddle River, New Jersey 07458
All rights reserved.