Vous êtes sur la page 1sur 39

Microprocessor and Microcontroller

Spring 2013

Lecture 1: Introduction
Muhammad Saqib Bhatti

COURSE SUPERVISOR
MUHAMMAD SAQIB BHATTI
Bachelors Degree in Telecommunication

engineering (NUCES-FAST). Graduated in 2008 Masters Degree in Electronics Engineering (University of Portsmouth UK). Cisco, Juniper and Huawei certified Network Professional in Routing and Switching. Worked as a Network Engineer in Virgin Media UK and Interactive Convergence Islamabad.

Course Details
Total Credit hours : 4

Lecture Timings
Wednesday : 9:35 - 11:05 (75 mins) Friday : 9:35 - 11:05 (75 mins) Lab Session : Tuesday : 1:15 - 2:45

Text Books
Pre- Requisites : Computer Architecture

Text Books:
Microprocessor and Microcontrollers, Krishna Kant

Eastern Company Edition, Prentice Hall of India, New Delhi , 2007. Muhammad Ali Mazidi & Janice Gilli Mazidi, R.D.Kinely The 8051 Micro Controller and Embedded Systems, PHI Pearson Education, 5th Indian reprint, 2003.

Other References
R.S. Gaonkar, Microprocessor Architecture

Programming and Application, Wiley Eastern Ltd., New Delhi. The 8088 & 8086 Microprocessors , Walter A Tribal & Avtar Singh, Pearson, 2007, Fourth Edition Some of the topics would be covered from other books and would be provided on need to know basis.

Grading
The final Grade will be determined from a

weighted average of assignments, quizzes, project and exams as follows.


Quizzes Assignments

Labs + Project
Midterm Exam I & II Final Exam

5% 5% 20% 20 % 50 %

Lab Project
Lab Project would be weighted approximately

10% (after consultation with the Lab supervisor) A final lab project will last 3-4 weeks. Projects will be self-selected or supervisor allocated would be told in the next Lecture. Project would be designing scenario.

Course Objective
to develop an in-depth understanding of
the operation of microprocessors and

microcontrollers machine language programming microprocessor interfacing techniques


to be able to use 8051 microcontroller

competently to be able to design and implement microprocessor-based systems in both hardware and software to be able to apply this knowledge to more advanced structures

At the high end of the scale


Processor: Intel Pentium 4 Frequency: 3.2GHz Power consumption: 103 W max.* Process: 90nm
*Intel document no. 300561-002

At the low end of the scale


Processor can consume no more than 250-300mW

Embedded Devices

Where are the embedded devices?

Course Objective
to develop an in-depth understanding of
the operation of microprocessors and

microcontrollers machine language programming microprocessor interfacing techniques


to be able to use 8051 microcontroller

competently to be able to design and implement microprocessor-based systems in both hardware and software to be able to apply this knowledge to more advanced structures

Evolution of Microcontrollers
1947 :- Invention of Transirstos 1959 :- Invention of Integrated Cicuits 1965 :- Birth of Moores Law 1971 :- Development of Microprocessors 1976 :- Inroduction of Mirocontrollers

Transistors
Transistors can be regarded as a type of switch,

as can many electronic components. They are used in a variety of circuits and you will find that it is rare that a circuit built in a school Technology Department does not contain at least one transistor. They are central to electronics. Vacuum Tubes were used before transistors but they were bulky, consumed a lot of power and were unreliable. Silicon and Germanium were used in the making transistors as they can carry current with small amount of impurities.

Transistors

Integrated circuits
Integrated Circuits play a very important part in

electronics. Most are specially made for a specific task and contain up to thousands of transistors, diodes and resistors. Special purposes IC's such as audio-amplifiers, FM radios, logic blocks, regulators ICs can be made very compact, having up to several billion transistors and other electronic components in an area the size of a fingernail. The width of each conducting line in a circuit (the line width) can be made smaller and smaller as the technology advances, in 2008 it dropped below 100 nanometers and in 2013 it is expected to be in the teens of

Integrated Circuits
Emplyee of Texas Instruments, Kilby recorded his

initial ideas concerning the integrated circuit in July 1958, successfully demonstrating the first working integrated example on 12 September 1958. In his patent application of 6 February 1959, Kilby described his new device as a body of semiconductor material ... wherein all the components of the electronic circuit are completely integrated.The first customer for the new invention was the US Air Force.
Kilby won the 2000 Nobel Prize in Physics for his part

of the invention of the integrated circuit. Kilby's work was named an IEEE Milestone in 2009.

Integrated Circuits

Gordon Moore, 1929 Cofounded Intel in 1968

with Robert Noyce. Moores Law: the number of transistors on a computer chip doubles every year (observed in 1965) Since 1975, transistor counts have doubled every two years.

Moores law
IEEE patent :- Cramming more components onto

Integrated Circuits
If the automobile had followed the same

development cycle as the computer, a Rolls-Royce would today cost $100, get a million miles per gallon, and explode once a year, killing everyone inside. Robert X. Cringely
1975 :- Dynamic RAM developed by intel
Contained 64000 transistors on a single chip

Moores law

Moores Law

Microprocessor
First microprocessor developed was 4004 by the

Company named Intel and was designed mainly for the usage in Calculator It is reckoned as a CPU-on-a-chip The microprocessor taught in this course would be 8086 and 8088 microprocessor.

Microcontroller
The first micro-controller developed was 8048 by

again our faverouite Intel It is reckoned as Computer-on-a-chip The microcontroller we will be studying in this course would be 8051

Microcontroller

Introduction to Microprocessors
What is a microprocessor?

Yes, but so much more than these Traditional Computers PCs, MACs, Linux,

workstation, desktop, laptop, tablet etc. Almost every electronic device employs one or more microprocessors to implement required functionality

What is a microprocessor?
A microprocessor is the central processing unit

(CPU) of a stored program digital computer implemented as a single chip integrated circuit.

OK so what is a stored program digital

computer ? Lets start with what is a computer? A computer is machine that can be programmed to perform a set of logical & mathematical operations on data

CPU-on-a-Chip
Concept evolved into well known digital computer

architecture:

Microprocessor tree

General-Purpose Processors
General Purpose Processors started from the

microprocessors 4004 as discussed earlier Went through 8008 8080 8085 8086 8088 80388 Pentium RISC - CISC 8086 is a 16-bit microprocessor Latest processor being 64-bit RISC : Reduced instruction Set Architecture Examples : Alpha, ARC, MIPS etc CISC Complex Instruction set Architectue Examples : Motorola 68000 family, Intel x86 CPUs

Special Purpose Processor


Embedded System is a special purpose

computer system (HW and SW) designed to perform some specific function Unlike
general purpose computer, performs few predefined tasks with well defined requirements and limitations Usually includes task specific hardware (peripherals) Software usually stored in non-volatile media and known as firmware Some common examples are DSP boards (2920), TMS-320, Comm Processors, uP 7720

Elements of Microcomputer System


Program is stored in memory as a sequence of

machine code instructions each machine code instruction occupies one or more memory locations each machine code instruction consists of a pattern of 1s and 0s which determine operation to be performed by the CPU mapping of machine code instructions to CPU operations is sometimes called instruction set architecture

Elements of Microcomputer System

CPU Control Unit


Contains special register known as program counter

contains memory address of next instruction to be executed Control unit fetches from memory the machine code instruction whose address is given by the program counter Control unit decodes the instruction Control unit executes the instruction including:
fetching required data operands from registers and/or

memory controlling ALU to perform any required data operation storing any results in registers and/or memory updating program counter to point to address of next instruction to be executed

Control Unit
Program instructions are normally stored in

sequential locations in memory Control unit recognizes (conditional) branch instructions which alter the normal program flow

CPU Datapath - Registers


Temporary storage location inside CPU
Hold data or address of data to be processed Provide operands to ALU and store results from

ALU registers can range from: 1 (simple microcontroller with accumulator) to over 100 (128 in Intel Itanium) Status (condition code) register holds bits (flags) that reflect result of last ALU operation (e.g. carry, zero, sign) Faster access than memory (fewer clock cycles)

Arithmetic & Logic Unit (ALU)


Performs simple arithmetic and logic operations

on data stored in registers and/or memory Add, subtract, and, or, shift, increment, multiply, etc. Operation depends on current machine code instruction Simple operations (register to register add) may execute in one clock cycle May include special purpose complex operations e.g. square-root, floating point, divide, complex number arithmetic typically take multiple clock cycles Results stored in registers and/or memory Status register updated according to result

Basic Instruction Cycle

Basic Instruction Cycle


Fetch:
Read machine code instruction from memory at address

supplied by program counter (PC) May take multiple memory cycles if instruction occupies more than one memory location
Decode : Determine operations to be performed and

generate microcode bits to control CPU hardware Execute:


Fetch required operands from memory and/or registers Perform required ALU operations Store results in registers and/or memory Update PC

Vous aimerez peut-être aussi