CE324_Lec4_The 8051 microcontrollers_SP25
CE324_Lec4_The 8051 microcontrollers_SP25
MICROPROCESSOR
I N T E R FA C I N G
1
Objectives
After completing this chapter of the book, you would be able to:
Compare the microprocessors and microcontrollers
Describe the advantages of the microcontrollers for some applications
Explain the concept of embedded systems
Discuss the criteria for considering a microcontroller
Explain the variations of speed, packaging, memory and cost per unit
and how these effect the choice of a microcontroller
Compare the various members of the 8051 family
Compare 8051 microcontrollers offered by various manufacturers
2
Outlines
Microcontrollers and embedded processors
Differences between microcontrollers and
microprocessors
Embedded processors: microprocessors targeted
towards embedded market
Criteria for choosing a microcontroller
Overview of the 8051 family
Various versions of 8051 family being offered by
different manufacturers
3
Microcontrollers and
embedded processor
4
Microcontroller vs General purpose
microprocessor
5
Microcontroller vs General purpose
microprocessor (Contd)
6
Microcontroller vs General Purpose
Microprocessor (Contd)
A designer using general purpose microprocessor e.g. the Pentium, needs to add
the peripherals externally to make them useful
Although adding peripherals makes the systems bulkier and more expensive, but
they are versatile i.e. ROM, RAM etc added as per requirements
In comparison, these peripherals inbuilt on a single chip in microcontrollers so
the designer cannot add any external I/O, memory or timer to it
Fixed amount of on-chip ROM, RAM and I/O ports however, make
microcontrollers ideal for applications in which cost and space are critical e.g. in
TV remote, we do not need the power of an 8086 microprocessor
In many applications, the space, power consumed and price per unit are more
critical than the processing power
Some manufacturers have even got ADCs and other peripherals integrated into
the microcontrollers
7
Microcontrollers for embedded systems
8
Microcontrollers for embedded systems (Contd)
Some embedded products using microcontrollers
9
x86 PC embedded applications
Although microcontrollers are the preferred choice for many applications,
sometimes a microcontroller is inadequate for the task
For this reason, many manufactures of general-purpose microprocessors
have targeted their microprocessor for the high-end of the embedded
market
When a company targets a general-purpose microprocessor for the
embedded market, it optimizes the processor used for embedded systems
For this reason, these processors are sometimes called high-end
embedded processors
Very often, the terms embedded processor and microcontroller are used
interchangeably
x86 used to denote the microprocessor family based on the Intel 8086 and
8088 microprocessors
10
x86 PC embedded applications (Contd)
One of the most critical needs of an embedded system is to reduce
power consumption and space requirement
In high-performance embedded processors, the trend is to integrate
more functions on CPU chip (thus reducing power & space utilization)
& let designer decide which features need to be used
The trend has invaded PC design with a chip containing the entire
PC apart from some components e.g. DRAMs, i.e. computer on a chip
In many cases (due to MS-DOS & Windows standardization) using
x86 PCs for the high-end embedded applications offers benefits:
Vast library of SW already written for the DOS and Windows platforms
Windows widely used & understood platform so developing windows-
based embedded product reduces cost & shortens development time
11
Choosing a microcontroller
Four major 8-bit microcontrollers i.e. most available
operations are limited to 8 bits
Motorola’s 6811
Intel’s 8051
Zilog’s Z8
Microchip’s PIC
Each one having its own instruction and register set and
are thus, not compatible with each other i.e. a program
written for one will not run on others
There are also 16-bit and 32-bit microcontrollers made by
various chip makers
12
Microcontroller choice criteria
Three basic criteria used to select among
the available microcontrollers
Meeting the computing needs of the task at hand
efficiently and cost effectively
Availability of software development tools, such as
compilers, assemblers, and debuggers
Wide availability and reliable sources of the
microcontroller according to needs both for now and
for future
13
Criteria (Contd)
Meeting the computing needs of the task at hand
efficiently and cost effectively
Speed: Max speed that the microcontroller supports
Packaging: 40-pin DIP (dual inline package) or a QFP (quad flat
package) or some other package as is important in terms of space,
assembling and prototyping the end product
Power consumption: Especially important for battery-powered
products
The amount of RAM and ROM on chip
The number of I/O pins and the timer on chip
How easy to upgrade to higher-performance or lower power-
consumption versions?
Cost per unit: Important in terms of the cost of the final product
14
Criteria (Contd)
Availability of software development tools, such as code-
efficient C language compilers, assemblers, debuggers, emulator,
technical support and both in house and outside expertise
Wide availability and reliable sources of the microcontroller
The 8051 family has the largest number of diversified suppliers
15
Overview of the 8051
family
16
8051 microcontroller
17
The 8051 microcontroller (Contd)
18
The 8051 family
19
Various 8051 microcontrollers
Although the 8051 is the most popular member of the 8051
family, you won’t see “8051” in the part number
This is because the 8051 is available in various memory
types, all of which having different part numbers
UV-EPROM:
To erase data stored in the transistor arrays, UV light is directed onto the die
Flash ROM:
Flash memory is an EEPROM (electronically erasable programmable ROM)
form of computer memory and thus, does not require a power source to
retain the data
NV-RAM (Non volatile-Random Access Memory):
RAM that retains data without applied power.
20
8051: UV-EPROM
8751 microcontroller
Only 4kBytes of on-chip UV-EPROM
Using this chip for development requires access to a
PROM burner as well as UV-EPROM eraser to erase the
contents of UV-EPROM before it can be programmed
again.
UV-EPROM takes around 20mins to erase 8751 before it
can be programmed again
This has led many manufacturers to introduce flash and
NV-RAM versions of 8051
21
8051: Flash memory
AT89C51 from Atmel corporation
Ideal for development since flash memory can be erased in seconds unlike
the 20mins or more needed for 8751
Development using AT89C51 needs a ROM burner that supports erasing the
flash memory as well thus, eliminating the need of a separate ROM eraser
In flash memory, the ROM contents MUST BE erased completely before it
can be programmed again
22
8051: NV-RAM and OTP
DS5000 from Dallas Semiconductor
The advantage of NV-RAM is the ability to change ROM components one
byte at a time
The DS5000 also comes with a loader, allowing it to be programmed through
the PC’s COM port
23
Summary
Role and importance of microcontrollers in everyday life
were discussed
Microprocessors and microcontrollers were contrasted
Use of microcontrollers in the embedded market was
discussed as well
The criteria for microcontroller selection and an
overview of the various versions of the 8051
microcontroller was also considered
24
Next time
25