Embedded System 09-01-2021 KBP
Embedded System 09-01-2021 KBP
By
Dr. V.D.Bachuwar
Asst. Prof.
Dept. of Electronics Science
School of Physical Sciences
Punyashlok Ahilyadevi Holkar Solapur
University, Solapur
What is Embedded System?
• An embedded system is a microprocessor/ microcontroller-based computer hardware
system with software that is designed to perform a dedicated function, either as an
independent system or as a part of a large system. At the core is an integrated circuit
designed to carry out computation for real-time operations.
• A system is an arrangement in which all its unit assemble work together according to a
set of rules. It can also be defined as a way of working, organizing or doing one or
many tasks according to a fixed plan..
Dr. V.D.Bachuwar 2
Embedded System Block Diagram
Dr. V.D.Bachuwar 3
Some Real Time Applications of Embedded
System
Dr. V.D.Bachuwar 4
The Microcontroller
• 8051 • A microcontroller is a compact integrated circuit designed to govern a
• AVR specific operation in an embedded system.
• A typical microcontroller includes a processor, memory and input/output
• PIC (I/O) peripherals on a single chip.
• ARM
• MSP
• Arduino
• SoC
Dr. V.D.Bachuwar 5
Difference between Microprocessor and Microcontroller
Microcontroller Microprocessor
Microcontrollers are used to execute Microprocessors are used for big
a single task within an application. applications.
Its designing and hardware cost is Its designing and hardware cost is high.
low.
Dr. V.D.Bachuwar 8
Computer Architectures
Dr. V.D.Bachuwar 9
VON NEUMANN ARCHITECTURE HARVARD ARCHITECTURE
Same physical memory address is used for Separate physical memory address is used for
instructions and data. instructions and data.
There is common bus for data and instruction Separate buses are used for transferring data and
transfer. instruction.
CPU can not access instructions and read/write CPU can access instructions and read/write at
at the same time. the same time.
It is used in personal computers and small It is used in micro controllers and signal
computers. processing.
Dr. V.D.Bachuwar 10
8051 Family
AT89C51,AT89C52, AT89S51,AT89S52
P89V51RD2BN
Dr. V.D.Bachuwar 12
8051 Architecture
• 8 bit microcontroller
• Max ROM – 64KB
• RAM – 128 bytes
• Frequency – 4 to 30
MHz
• Ports – 4
(P0,P1,P2,P3)
• Timers- 2 Timers ( 16
bit)
• Serial
Communication
• External Interrupts
Dr. V.D.Bachuwar 13
Registers in 8051 Microcontroller
• The Data Pointer (DPTR) is the 8051’s only user-accessible 16-bit (2-byte)
register. The Accumulator, R0–R7 registers and B register are 1-byte value
registers. DPTR is meant for pointing to data. It is used by the 8051 to access
external memory using the address indicated by DPTR. DPTR is the only 16-bit
register available and is often used to store 2-byte values.
• The Program Counter (PC) is a 2-byte address which tells the 8051 where the
next instruction to execute can be found in the memory. PC starts at 0000h when
the 8051 initializes and is incremented every time after an instruction is
executed. PC is not always incremented by 1. Some instructions may require 2 or
3 bytes; in such cases, the PC will be incremented by 2 or 3.
Dr. V.D.Bachuwar 14
Program Status Word (PSW)
Dr. V.D.Bachuwar 15
Dr. V.D.Bachuwar 16
Assembly Language Programming
Dr. V.D.Bachuwar 17
Integrated Development Environment(IDE)
.hex file
Dr. V.D.Bachuwar 18
Port Programming
Dr. V.D.Bachuwar 19
LED ON and OFF Logic
Logic 1 i.e. 5V LED ON Logic 0 i.e. 0V LED OFF
Dr. V.D.Bachuwar 20
P0.7 P0.6 P0.5 P0.4 P0.3 P0.2 P0.1 P0.0
0 0 0 0 0 0 0 0 00H
0 0 0 0 0 0 0 1 01H
0 0 0 0 0 0 1 0 02H
Dr. V.D.Bachuwar 21
P0.7 P0.6 P0.5 P0.4 P0.3 P0.2 P0.1 P0.0
0 0 0 0 0 1 0 0 04H
0 0 0 0 1 0 0 0 08H
0 0 0 1 0 0 0 0 10H
Dr. V.D.Bachuwar 22
P0.7 P0.6 P0.5 P0.4 P0.3 P0.2 P0.1 P0.0
0 0 1 0 0 0 0 0 20H
0 1 0 0 0 0 0 0 40H
1 0 0 0 0 0 0 0 80H
Dr. V.D.Bachuwar 23
ORG 00H
START: MOV P0,#00H DELAY:
MOV R1,#255
CALL DELAY
UP: DJNZ R1, UP
MOV P0,#01H RET
CALL DELAY
MOV P0,#02H
CALL DELAY
MOV P0,#04H
CALL DELAY
MOV P0,#08H
CALL DELAY
MOV P0,#10H
CALL DELAY
MOV P0,#20H
CALL DELAY
MOV P0,#40H
CALL DELAY
MOV P0,#80H
CALL DELAY Dr. V.D.Bachuwar 24
Dr. V.D.Bachuwar 25
8051 Boards for Projects
489.00/-
https://robu.in/product/smartelex-aryabhatta-8051-microcontroller-develop
ment-board-at89s52-with-onboard-usb-programmer/?gclid=CjwKCAiA_9r_BR
BZEiwAHZ_v10eOsLJldHHDUkWSDMYcQE4KxsjljXPnP08UXD8ghJwNaJ35_zrdg
hoCIasQAvD_BwE
Dr. V.D.Bachuwar 26