microprocessor
DESCRIPTION
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 - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/1.jpg)
Microprocessor Al-Azhar University
Lecture 1Dr. Mohamed Ezz
Dr. Ali Halawa
![Page 2: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/2.jpg)
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
Class Materials
2
![Page 3: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/3.jpg)
2 Lectures Weekly
1 Class Weekly
.
3
Schedule and Arrangement
![Page 4: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/4.jpg)
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
4
Participation
![Page 5: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/5.jpg)
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
5
Assignments and Quizzes
![Page 6: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/6.jpg)
Lets Get Started
6
![Page 7: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/7.jpg)
The Electronic Numerical Integrator and Computer (ENIAC) begins in 1938
![Page 8: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/8.jpg)
The Computer Evolution
Mainframe
Computer, 1960
The P
C, 198
0
Mob
ile
Compu
ter 1
990
Mini-Computer, 1
970
![Page 9: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/9.jpg)
9
![Page 10: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/10.jpg)
History
Company
4 bit 8 bit 16 bit 32 bit 64 bit
intel40044040
800880808085
8088/68018680286
8038680486
80860pentium
zilog Z80Z8000Z8001Z8002
Motorola680068026809
680066800868010
680206803068040
![Page 11: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/11.jpg)
The History of Intel’s Microprocessors
![Page 12: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/12.jpg)
Home computer as imagined more than 50 years ago
![Page 13: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/13.jpg)
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
Moore’s Law
![Page 14: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/14.jpg)
![Page 15: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/15.jpg)
year
log
(p
eop
le p
er
com
pu
ter)
Streaming Data to/from the
Physical World
Excerpted from ‘The Mote Revolution: Low Power Wireless Sensor Network’, UCB, 2004.
Bell’s Law: New computing class every 10 years
![Page 16: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/16.jpg)
16
Why do we study this stuff?
Applications
OperatingSystems
ComputerSystem
(CPU rules)
![Page 17: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/17.jpg)
It is inside of every device that we have such as computer , printers , mobile , etc..
17
Where is the Microprocessor ?
![Page 18: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/18.jpg)
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
18
What is the Microprocessor?
![Page 19: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/19.jpg)
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)
![Page 20: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/20.jpg)
20
Lecture 2
![Page 21: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/21.jpg)
21
Block Diagram of a Computer
![Page 22: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/22.jpg)
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
The Microprocessor (MPU)
![Page 23: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/23.jpg)
Microprocessors
They accept programs
![Page 24: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/24.jpg)
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.
ALU
![Page 25: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/25.jpg)
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.
Control Logic
![Page 26: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/26.jpg)
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
![Page 27: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/27.jpg)
There are three main bus groups◦ ADDRESS BUS◦ DATA BUS◦ CONTROL BUS
Bus
![Page 28: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/28.jpg)
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.
Length of Data Word
![Page 29: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/29.jpg)
Hardware Physical Devices Program a group of instructions preformed by the
microprocessor Software a group of programs
29
The System Components
Microprocessor
Memory
I/O
![Page 30: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/30.jpg)
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
30
Microprocessor vs. Microcontroller
![Page 31: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/31.jpg)
Microcontroller
One- chip
Microprocessor vs. Microcontroller
31
Microprocessor
Memory
I/O
![Page 32: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/32.jpg)
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-bitsTherefore, the processor is named after the word size.
e.g. We say “ 8-bit Microprocessor”
32
What numbering System a Microprocessor Uses?
![Page 33: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/33.jpg)
33
The Memory
![Page 34: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/34.jpg)
Word Addressing
34
Given M words (location to access), how many bits l are required to address them?
Example: to address 64 MB, we need
Ml 2log
bitsl 26)2*2*2(log)2*2*64(log 101062
10102
![Page 35: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/35.jpg)
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
Memory Word
![Page 36: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/36.jpg)
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
apart0
1
2
3
4
5
6
...
8 bits of data
8 bits of data
8 bits of data
8 bits of data
8 bits of data
8 bits of data
8 bits of data
![Page 37: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/37.jpg)
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
![Page 38: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/38.jpg)
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
Types of Memory (Cont.)
![Page 39: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/39.jpg)
The idea ◦ Hide the slower memory behind the fast memory ◦ Cost and performance play major roles in selecting the memory.
Memory Hierarchy
![Page 40: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/40.jpg)
40
![Page 41: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/41.jpg)
![Page 42: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/42.jpg)
42
Computer Languages
![Page 43: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/43.jpg)
43
Computer Languages
![Page 44: Microprocessor](https://reader035.vdocuments.us/reader035/viewer/2022062421/56812af3550346895d8ed777/html5/thumbnails/44.jpg)
Sample of Z80 Language
44
Assembly Language (mnemonic form)
Machine Language