3. A microcomputer is a computer similar to any other
computer, except that the CPU functions of the
microcomputer are performed by the microprocessor.
The MPU (microprocessor unit) is the heart of every
microcomputer. It performs a number of functions, including.
1. Providing timing and control signals for all elements of the
µC
2. Fetching instructions and data from memory 3.
Transferring data to and from memory and I/O devices
4. Decoding instructions
5. Performing arithmetic and logic operations called for by
instructions
6. Responding to I/O generated control signals such as
RESET and INTERRUPT.
Microprocessor.
4. Inside the Microprocessor.
• Internally, the microprocessor is made
up of 3 main units.
– The Arithmetic/Logic Unit (ALU)
– The Control Unit, memory unit
– An array of registers for holding data while. it is
being manipulated.
_ input unit and output unit.
Organization of a Microprocessor based system
5. Arithmetic and Logic Unit : In this area of the microprocessor, computing
functions are performed on data. The CPU performs arithmetic operations such
as addition and subtraction, and logic operations such as AND, OR, and exclusive
OR. Results are stored either in register or in memory or sent to output devices.
Register Unit : This area of the microprocessor consists of various registers. The
register are used primarily to store data temporarily during the executing of a
program. Some of the registers are accessible to the user through instructions.
Control Unit : The control unit provides the necessary timing and control signals
to all the operations in the microcomputer. It controls the flow of data between the
microprocessor and peripherals (including memory).
input unit: The input section transfers data and instructions in binary from the
outside world to the microprocessor.
output unit : The output section transfers data from the microprocessor to output
devices Output.
Memory unit: Memory stores binary information such as instructions and data,
and provides that information to the microprocessor whenever necessary.
system bus :The system bus is a communication path between the
microprocessor and the peripherals.
6. D7 D6 D5 D4 D3 D2 D1 D0
S Z AC P CY
General purpose register
There are 6 general purpose registers in 8085 processor, i.e. B, C, D, E, H & L. Each register can
hold 8-bit data.
These registers can work in pair to hold 16-bit data and their pairing combination is like B-C, D-E &
H-L.
Program counter
It is a 16-bit register used to store the memory address location of the next instruction to be
executed. Microprocessor increments the program whenever an instruction is being executed, so
that the program counter points to the memory address of the next instruction that is going to be
executed.
Stack pointer
It is also a 16-bit register works like stack, which is always incremented/decremented by 2 during
push & pop operations.
Temporary register
It is an 8-bit register, which holds the temporary data of arithmetic and logical operations.
Flag register
It is an 8-bit register having five 1-bit flip-flops, which holds either 0 or 1 depending upon the result
stored in the accumulator.
These are the set of 5 flip-flops −
•Sign (S)
•Zero (Z)
•Auxiliary Carry (AC)
•Parity (P)
•Carry (C)
Its bit position is shown in the following table −
7. Instruction register and decoder
It is an 8-bit register. When an instruction is fetched from memory then it is stored in the Instruction
register. Instruction decoder decodes the information present in the Instruction register.
Timing and control unit
It provides timing and control signal to the microprocessor to perform operations.
Address bus and data bus
Data bus carries the data to be stored. It is bidirectional, whereas address bus carries the location
to where it should be stored and it is unidirectional. It is used to transfer the data & Address I/O
devices.
9. •Integrated chip that typically contains integrated CPU, memory
(RAM ROM), I/O ports on a single Chip.
• System on a single Chip/ small computer on a single chip
•Designed to execute a specific task to control a single system
•Smaller & Specified (design cost)
•Differs from Microprocessor general
-purpose chip
-Used to design multi purpose computers or devices
-Require Multiple chips to handle various tasks
•Typically Microcontroller embedded inside some device
• Microcontrollers are important part of Embedded systems
Microcontroller
10. The features of a microcontroller are similar to that of a
microprocessor like registers, ALU, program counter, flags, stack
pointer, etc. Along with these common features, a microcontroller has
some additional features such as a clock circuit, internal RAM, ROM,
serial and parallel I/O counter.
An microcontroller has the following 12 major
components:
1. ALU (Arithmetic and Logic Unit)
2. PC (Program Counter)
3. Registers
4. Timers and counters
5. Internal RAM and ROM
6. Four general purpose parallel input/output ports
7. Interrupt control logic with five sources of interrupt
8. Serial date communication
9. PSW (Program Status Word)
10. Data Pointer (DPTR)
11. Stack Pointer (SP)
12. Data and Address bus
11. Microcontroller Microprocessor
Microcontrollers are used to
execute a single task within an
application.
Microprocessors are used for big
applications.
Its designing and hardware cost
is low.
Its designing and hardware cost is
high.
Easy to replace. Not so easy to replace.
It is built with CMOS technology,
which requires less power to
operate.
Its power consumption is high
because it has to control the entire
system.
It consists of CPU, RAM, ROM, I/
O ports.
It doesn’t consist of RAM, ROM, I/O
ports. It uses its pins to interface to
peripheral devices.
Difference between Microprocessor and
Microcontroller