1. 1
PRESENTED TO: PRESENTED BY:
NEERAJ KUMAR CHASTA VINOD KUMAR YADAV
(12EC094)
DEPARTMENT OF ELECTRONICS & COMMUNICATION ENGINEERING
Badlya Chuoraha, N.H. 8, By-Pass, Ajmer-305002
Website: www.ecajmer.ac.in,Ph no. 0145-2717736, 776,800,801
2. 2
CONTENTS
1. ABOUT THE COMPANY
2. ABOUT EMBEDDED SYSTEMS
Examples In Your Daily Life
Design Challenges
Architecture of embedded system
Major Application areas of Embedded System
Advantage
3. MICROCONTROLLER
8051 Microcontroller
Pin Description Of The 8051
Applications
Salient Features Of 8051 Microcontroller
3. 3
4.C PROGRAMMING TECHNIQUES FOR 8051
Key Features Of Embedded C-
Header File For 8051 Microcontroller
Supports Following Data Types
5.INTERFACING
Need Of Interfacing
Interfacing -Basics
Interfacing With Led
Seven Segment Leds
Keypad Interfacing
4. 4
It is an autonomous body of the Government of Rajasthan under the Department of
Technical Education.
Foundation stone of CEG was laid down on 8th December 2006 at Jaipur.
Rajasthan is the second state that is running this program after the highly acclaimed and
successful program "Jawahar Knowledge Centre" in Andhra Pradesh.
Provides a conducive environment for creating industry employable IT professionals by
the way of arranging seminars lecturers, vocational trainings and industry relevant
software trainings.
Provides training in embedded system, C++ , java ,CCNA networking, CCNP, VLSI
Technology, WAB Development etc.
1. ABOUT THE COMPANY
5. 5
2. ABOUT EMBEDDED SYSTEMS
Embedded Systems- Definition
“An embedded system is a system that has software embedded into computer-
hardware, which makes a system dedicated for an application(s) or specific part of
an application or product or part of a larger system.”
It is any device that includes a programmable computer but is not itself intended to
be a general purpose computer.”
HARDWARE
6. 6
Combination of both hardware and software
Designed to perform specific function
A system that has embedded software and hardware, that makes it a dedicated
system for a specific application or a part of application or product is called
Embedded System.
7. Examples In Your Daily Life
Wake up…
have breakfast …
set home safety system …
get into your car …
on your way to your office…
7
12. 12
Major Application areas of Embedded
System
Consumer electronics: Camcorders, Cameras, etc.
Household appliances: TV, DVD players, washing machine, refrigerator, oven, etc.
Home automation & Security system: Air conditioners, sprinklers, intruder
detection alarms, fire alarms, etc.
Automotive industry: Anti-lock breaking system (ABS), engine control, ignition
systems, automatic navigation system, etc.
Telecom: Cellular telephones, handset, etc.
Computer peripherals: printers, scanners, fax, machines, etc.
Healthcare: scanners, EEG, ECG, etc.
Measurement & Instrumentation: Digital multi meters, digital CRO’s, etc.
Banking& Retail: Automatic Teller Machine (ATM), currency counter, etc.
Card Readers: barcode, smart card readers, handheld devices, etc.
13. 13
Advantage
They are designed to do a specific task and have real time performance constraints
which must be met.
They allow the system hardware to be simplified so costs are reduced.
They are usually in the form of small computerized parts in larger devices which
serve a general purpose.
The program instructions for embedded systems run with limited computer
hardware resources, little memory and small or even non-existent keyboard or
screen.
15. 15
3.MICROCONTROLLER
A microcontroller is a functional computer system-on-a-chip. It contains a
processor, 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.
17. 17
8051 Microcontroller
Single Chip Microcontroller (µc)
Developed By Intel In 1980 For Use In Embedded Systems
First Microcontroller Of The Mcs-51family
It Is A Low-power, High-performance CMOS 8-bit Microcontroller With 4K Bytes Of
In-system Programmable Flash Memory, 128 Bytes Of RAM, 32 I/O Lines, Watchdog
Timer, Two Data Pointers, Two 16-bit Timer/Counters, A Five-vector Two-level
Interrupt Architecture, A Full Duplex Serial Port, On-chip Oscillator, And Clock
Circuitry.
A Microcontroller Is An Economical Computer-on-a-chip For Doing With Specific
Tasks, Such As Displaying Or Receiving Information Through LED Or Remote
Controlled Devices.
18. 18
Pin Description Of The 8051
The 8051 microcontroller is available as a 40 pin DIP chip.
Works at +5 volts DC
Among the 40 pins , a total of 32 pins are allotted for the four parallel ports
P0,P1,P2 and P3 i.e. each port occupies 8-pins.
The remaining pins are VCC, GND, XTAL1, XTAL2, RST, EA ,PSEN,ALE.
20. 20
Salient Features Of 8051 Microcontroller:
8-bit CPU (CPU can work on only 8 bits of data at a time)
Two 16 bit timers/counters
128 bytes of RAM
4K bytes of on-chip ROM
One serial port
8-bit data bus
16-bit address bus
One 16-bit program counter and One 16-bit DPTR ( data pointer)
One 8-bit stack pointer
32 general purpose registers each of 8 bits
Four I/O ports, each 8 bits wide
On-chip clock oscillator
Control registers: TCON, TMOD, SCON, PCON, IP and IE.
21. 21
Household appliances:
Microwave ovens, Television, DVD
Players & Recorders
Audio players
Integrated systems in aircrafts and
missiles
Cellular telephones
Electric and Electronic Motor
controllers
Engine controllers in automobiles
Calculators
Medical equipments etc...
APPLICATIONS
22. 22
Key Features Of Embedded C-
4.C PROGRAMMING TECHNIQUES FOR 8051
It is easy and less time consuming to write in C than Assembly.
C is easier to modify and update.
You can use code available in function libraries.
C code is portable to other microcontroller with little of no modification.
A good understanding of C data types for 8051 can help programmers to
create smaller hex files
23. 23
Header File For 8051 Microcontroller
#include<reg51.h>
#define variable
Void main()
{
- - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - -
}
Supports following data types-
Unsigned char
Signed char
Unsigned int
Signed int
24. 24
Sbit (single bit)
Bit
Note:-C compilers use the signed char as the default if we do not put the keyword
Unsigned.
sbit Type
The PIC compiler has sbit data type, which provides access to bit addressable
internal registers (SFRs). You can access bits of internal registers, as in the following
examples:
sbit LED= P1^0; //LED is assigned to bit 0 of PORT 1
Data types Size Range
bit 1-bit RAM bit-addressable only
sbit 1-bit SFR bit-addressable only
(signed) int 16-bit -32768 to +32767
unsigned int 16-bit 0 to 65535
(signed) char 8-bit -128 to +127
unsigned char 8-bit 0 to 255
//SFR= specific function register.
25. 25
5.INTERFACING
Transfer of data between microcontrollers and peripherals (memory, I/O devices
etc.) implemented using buses called interfacing.
Connecting the computation capabilities of a microcontroller to external signals or
to external world.
Creating man-machine interaction.
26. 26
NEED OF INTERFACING
The basic need is to have some input/output peripherals and man-machine interface.
Interactions with a computer or TV are possible using the mouse /keyboard/display
screen.
The no. of real world devices and systems like mobile phone and washing m/c need
the keypad and display to enable human-computer interactions.
28. 28
INTERFACING WITH LED
The Anode is connected through a resistor to GND & the Cathode is connected to the
Microcontroller pin. So when the Port Pin is HIGH the LED is OFF & when the Port Pin
is LOW the LED is turned ON.
29. 29
Two Approaches 1.column scanning
2.row scanning
We are using column scanning.
Making each row 1 and others 0 and then
scan the each column
If any switch pressed corresponding
column's sense value is 0
The pressed switch make the corresponding
column and row shorted.
Tow scanning is just the opposite of the
column scanning technique.
KEYPAD INTERFACING