1.07k likes | 1.89k Views
Microprocessor. Al-Azhar University Lecture 1 Dr. Mohamed Ezz Dr. Ali Halawa. Class Materials. Text book Ramesh S. Gaonkar, The Z80 Microprocessor architecture , Interfacing, Programming, and Design,. Term paper/Project Select your topic or your project (HW) as early as possible
E N D
Microprocessor Al-Azhar University Lecture 1 Dr. Mohamed Ezz Dr. Ali Halawa
Class Materials • Text book • Ramesh S. Gaonkar, The Z80 Microprocessor architecture , Interfacing, Programming, and Design,. • Term paper/Project • Select your topic or your project (HW) as early as possible • Group of max. 5 students 2
Schedule and Arrangement • 2 Lectures Weekly • 1 Class Weekly .
Participation • You are expected to attend all of the lectures • Exams will be based on the class materials • More than four absent will not attend final exam • Group Activities • Very Important
Assignments and Quizzes • Must be submitted on time • Late assignments will be accepted within one week with -25% penalties • Student will solve sheets questions in the Classes. Please come ready • Bonus points for first 5 student solve quiz in the class • All sheets questions must be solved by student • Exam in the class every 8 lectures
The Electronic Numerical Integrator and Computer (ENIAC) begins in 1938
Mainframe Computer, 1960 Mini-Computer, 1970 Mobile Computer 1990 The PC, 1980 The Computer Evolution
Moore’s Law 1965 prediction by Intel cofounder Gordon Moore: The number of transistors that can be built on the same size piece of silicon will double every 18 months
Bell’s Law:New computing class every 10 years log (people per computer) Streaming Data to/from the Physical World year Excerpted from ‘The Mote Revolution: Low Power Wireless Sensor Network’, UCB, 2004.
Why do we study this stuff? Applications Operating Systems Computer System (CPU rules)
Where is the Microprocessor ? • It is inside of every device that we have such as computer , printers , mobile , etc..
What is the Microprocessor? • It’s a semiconductor IC • Multipurpose , programmable logic device. • Reads Instructions from the Memory • Reading data from and writing data to memory and I/O • Performing arithmetic and logic ops • Process the data according to the instructions • Produces Output • Perform step-by-step procedure
The Microprocessor (MPU) • The uP is the ‘brain of the microcomputer’ • Is a single chip which is capable of • processing data • controlling all of the components which make up the microcomputer system • µP used to sequence executions of instructions that is in memory • uP Fetch , Decode , and Execute the instruction • The internal architecture of the microprocessor is complex.
The Microprocessor (MPU) • microprocessor (MPU) typically contains • Registers: Temporary storage locations for program instruction or data. • The Arithmetic Logic unit (ALU): This part of the MPU performs both arithmetic and logical operations • Timing and Control Circuits: that keep all of the other parts of system (Regs, ALU, memory & I/O) working together in the right time sequence
Microprocessors They accept programs
ALU • Computation is performed by logic circuits that make up the Arithmetic Logic Circuit (ALU) – Add, Subtract, AND, OR, Compare, Increment, and Decrement. • ALU cannot itself move data from place to place. • Like a blindfolded juggler – ALU must wait for data to be placed in certain places.
Control Logic • In order to process data, the microprocessor must have control logic which tells the microprocessor how to decode and execute the program – a set of instructions. • It fetches them one at a time and decodes the instruction. Then the control logic carries out or execute the decoded instruction. • It also controls how the microprocessor works with memory, input and output.
Bus • A Bus is a common communications pathway used to carry information between the various elements of a computer system • The term BUS refers to a group of wires or conduction tracks on a printed circuit board (PCB) though which binary information is transferred from one part of the microcomputer to another • The individual subsystems of the digital computer are connected through an interconnecting BUS system.
Bus • There are three main bus groups • ADDRESS BUS • DATA BUS • CONTROL BUS
Length of Data Word • Each microprocessor works on a data word of fixed length. • Word lengths of 4 bits, 8 bits, 16 bits, and 32 bits are most common. • 8-bit word length are common that it has been given the name byte. • Some 16-bit microprocessor have instruction s processed in two 8-bit bytes.
The System Components • Hardware Physical Devices • Program a group of instructions preformed by the microprocessor • Software a group of programs Microprocessor Memory I/O
Microprocessor vs. Microcontroller • A microcontroller contains a processor core, memory, and programmable input/output peripherals. • Microcontrollers include an integrated CPU, memory (a small amount of RAM, program memory, or both) and peripherals capable of input and output. • Microprocessor only contains a CPU (the kind used in a PC). In addition to the usual arithmetic and logic elements of a general purpose microprocessor, • The microprocessor includes some of the components on a chip and other components are used as peripherals. • The microcontroller includes all of the required components on one chip. • You can say that microcontroller = microprocessor + Motherboard (memory & I/O) in one chip
Microprocessor vs. Microcontroller Microcontroller One- chip Microprocessor Memory I/O
What numbering System a Microprocessor Uses? • Binary System • A Bit is 0 or 1 • The processor processes a group of bits called Word. • The word size could be: 8-bit, 16-bit, 32-bit, or 64-bits Therefore, the processor is named after the word size. e.g. We say “ 8-bit Microprocessor”
Given M words (location to access), how many bits l are required to address them? Example: to address 64 MB, we need Word Addressing
Memory Word • 8-bit microprocessors have an address range of 65,536 memory words in the 65,536 bytes memory • For the same memory size, 16-bit have 32,768 word memory. Question: A 16-bit word length is used by the 80286 microprocessor. If an 80286 addresses 32 kilo-words of memory, it memory will have _____ bits of data
0 8 bits of data 1 8 bits of data 2 8 bits of data 3 8 bits of data 4 8 bits of data 5 8 bits of data 6 8 bits of data ... Memory Organization Viewed as a large, single-dimension array, with an address A memory address is an index into the array "Byte addressing" means that successive addresses are one byte apart
Types of Memory • Cache Memory • Serves as a buffer for frequently accessed data • Small High Cost • RAM (Main Memory) • Stores programs and data that the computer needs when executing a program • Dynamic RAM (DRAM) • Uses Tiny Capacitors • Needs to be recharged every few milliseconds to keep the stored data • Static RAM (SRAM) • Holds its data as long as the power is on • D Flip Flop
Types of Memory (Cont.) • ROM • Stores critical information necessary to operate the system. • Hardwired can not be programmed • Programmable Read Only Memory (PROM) • Can be programmed once using appropriate equipment • Erasable PROM (EPROM) • Can be programmed with special tool • It has to be totally erased to be reprogrammed • Electrical Erasable PROM (EEPROM) • No special tools required • Can erase a portion
Memory Hierarchy • The idea • Hide the slower memory behind the fast memory • Cost and performance play major roles in selecting the memory.
Sample of Z80 Language Assembly Language (mnemonic form) Machine Language