SlideShare a Scribd company logo
1 of 48
Presentation By,
Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
CPU RAM ROM
Input/output Timers
Serial Com
port
Have you used Microcontroller ?
Please write your Answers in comment box
Name any one application
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 Micro- Size is small
 Controller- Which controls the
operations
 Microcontroller is small size device
which is used to perform and control
operations
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 Identify what are the features of this Smart
watch?
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
From next slide please identify
Microcontroller Applications
And
Write your answers in comment
section
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 Home Appliances
 Intercom
 Telephone
 TVs
 VCR
 Cable TV tuner
 Remote Controls
 Toys
 Microwave
 Lightening Controls
 Video Games
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 Telephones
 Copy Machine
 Paging
 Fax Machine
 Security Systems
 Laser Printer
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 4 bit Microcontroller
 8 bit Microcontroller
 16 bit Microcontroller
 32 bit Microcontroller
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 Embedded memory microcontroller:
8051 microcontroller
 External memory microcontroller: 8031
microcontroller
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 CISC: CISC is a Complex Instruction
Set Computer
 RISC: The RISC is stands for Reduced
Instruction set Computer
Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
 It is 8 bit microcontroller
 4k on chip ROM
 128 Bytes of on chip RAM
 4 Ports with 32 Input/Output Lines
 1 Serial Port
 2 Timers/Counter
 5 Interrupts
 A and B Register
 16 Bit Program Counter and DPTR
 8 bit Stack Pointer
 8 Bit Data bus
 16 bit Address bus
CPU 8 Bit
5 Interrupts
Timer/Counter 0
Timer/Counter 1
4 Ports
P0 P1 P2 P3
1 Serial Port
4 K ROM
for Program
Code
128 bytes
RAM
Bus Control
Unit
Oscillator
TXD RXD
Name Function Internal Address
(Hex)
A ACCUMULATOR 0E0
B ARITHMETIC 0F0
DPH Addressing External Memory 83
DPL Addressing External Memory 82
IE Interrupt Enable Control 0A8
IP Interrupt Priority 0B8
P0 Input/Output Port 0 Latch 80
P1 Input/Output Port 1 Latch 90
P2 Input/Output Port 2 Latch 0A0
P3 Input/Output Port 3 Latch 0B0
Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
Name Function Internal Address
(Hex)
PCON Power Control 87
PSW Program Status Word 0D0
SCON Serial Port Control 98
SBUF Serial Port Data Buffer 99
SP Stack Pointer 81
TMOD Timer/ Counter Mode Control 89
TCON Timer/ Counter Control 88
TL0 Timer 0 Low Byte 8A
TH0 Timer 0 High Byte 8C
TL1 Timer 1 Low Byte 8B
TH1 Timer 1 High Byte 8D
Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
Number of Pins Function
2 Vcc and Ground (40 , 20)
2 XTAL1 and XTAL2 (19, 18)
1 Reset (9)
3 PSEN, ALE, EA (29, 30, 31)
32 Input/output Port (P0, P1, P2, P3)
40 Total
Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
 The 8051 has four important ports P0, P1, P2 and P3
 These ports allow the microcontroller to connect with the
outside world
 Each port has 8 pins. Thus total 32 pins can be used as I/O
 All ports are bidirectional
 They are constructed with a D type output latch. They have
output drivers and input buffers
 All the ports are configured as input ports on Reset
 To configure ports as an input port 1 must be written to that
port
 To configure it as an output port 0 must be written to it
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
https://exploreembedded.com/wiki/1.8051_Architecture
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
https://exploreembedded.com/wiki/1.8051_Architecture
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
To read 0 from the pin of the microcontroller:
Write one to pin.
M1 turns OFF
Read PIN latch is turned ON
External zero grounds the pin
https://exploreembedded.com/wiki/1.8051_Architecture
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
https://exploreembedded.com/wiki/1.8051_Architecture
Write one to pin.
M1 turns OFF
Read PIN latch is turned ON
External vcc appears at the pin
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
https://electronicsdesk.com/pin-diagram-and-description-of-8051-microcontroller.html
 Port 0 have 8 pins which can be used as Input/ Output
 Address: 80H
 To configure ports as an input port 1 must be written to that
port
 To configure it as an output port 0 must be written to it
 An external pull-up resistor is needed when Port 0 is defined
as an output port
 Port 0 is used to access external memory in conjunction with
Port 2
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
 Port 1 have 8 pins which can be used as Input/ Output
 Address: 90H
 To configure ports as an input port 1 must be written to
that port
 To configure it as an output port 1 must be written to it
 An external pull-up resistor is not required when Port 1 is
defined as an output port
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
 Port 2 have 8 pins which can be used as Input/ Output
 Address: A0H
 To configure ports as an input port 2 must be written to
that port
 To configure it as an output port 2 must be written to it
 An external pull-up resistor is not required when Port 2 is
defined as an output port
 Port 2 is used to access external memory in conjunction
with Port 0
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
 Port 3 have 8 pins which can be used as Input/ Output
 Address: B0H
 To configure ports as an input port 3 must be written to
that port
 To configure it as an output port 3 must be written to it
 An external pull-up resistor is not required when Port 3 is
defined as an output port
 Port 3 have Alternate functions
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
RXD: used for a serial input port
TXD: used for serial output port
INT0: used for an external interrupt 0
INT1: used for external interrupt 1
T0: Timer 0 external input
T1: Timer 1 external input
WR: external data memory write strobe
RD: external data memory Read strobe
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
EA: External Access (Input Pin)
Ground – Program is Store in External Memory
Vcc - Program is stored on On-chip ROM
ALE: Address Latch Enable (output pin)
1 - Address
0 - Data
PSEN: Program Store Enable
It is used to read a signal from the external program
memory
It should be connected to OE/ CS pin of Memory
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
128x8
128 x 8
Address lines data lines
128=2^7 8
Address lines=7 that is from A0 to A6
Data lines=8 that is from D0 to D7
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Calculate number of address lines and data lines for
1. 256 x 8
2. 1K x 8
3. 2K x 8
4. 4K x 8
5. 8K x 8
6. 64 x 8
7. 512 x 8
8. 64 k x 8
9. 32K x 8
10. 16 K x 8
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Read
Write Memory
Chip select
Data
Bus
Address
Bus
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Read
Write Memory
(128x8)
Chip select
Da
ta
Bu
s
Address
Bus
8051
Microcontroller
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC

More Related Content

Similar to 8051Architecture_Basics.pptx

Microcontroller
MicrocontrollerMicrocontroller
Microcontroller
Spitiq
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
Rashmi
 
4th yr dmumicrocontroller1
4th yr dmumicrocontroller14th yr dmumicrocontroller1
4th yr dmumicrocontroller1
haymanotyehuala
 

Similar to 8051Architecture_Basics.pptx (20)

Micro lec note2
Micro lec note2Micro lec note2
Micro lec note2
 
8051 microcontroller
8051 microcontroller8051 microcontroller
8051 microcontroller
 
Micro lec note2 (1)
Micro lec note2 (1)Micro lec note2 (1)
Micro lec note2 (1)
 
8051 Microcontroller
8051 Microcontroller8051 Microcontroller
8051 Microcontroller
 
8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )
8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )
8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )
 
8051 microcontroller
8051 microcontroller 8051 microcontroller
8051 microcontroller
 
Microcontroller
MicrocontrollerMicrocontroller
Microcontroller
 
8051 Presentation
8051 Presentation8051 Presentation
8051 Presentation
 
Atmega 16 drdo report
Atmega 16 drdo reportAtmega 16 drdo report
Atmega 16 drdo report
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
 
MPI UNIT 5 - (INTERRUPTS OF 8086, INTRODUCTION TO 8051).pptx
MPI UNIT 5 - (INTERRUPTS OF 8086, INTRODUCTION TO 8051).pptxMPI UNIT 5 - (INTERRUPTS OF 8086, INTRODUCTION TO 8051).pptx
MPI UNIT 5 - (INTERRUPTS OF 8086, INTRODUCTION TO 8051).pptx
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
 
Microcontroller (8051) by K. Vijay Kumar
Microcontroller (8051) by K. Vijay KumarMicrocontroller (8051) by K. Vijay Kumar
Microcontroller (8051) by K. Vijay Kumar
 
8255_Ppi new
8255_Ppi new8255_Ppi new
8255_Ppi new
 
8051 microcontroller by K. Vijay Kumar
8051 microcontroller by K. Vijay Kumar8051 microcontroller by K. Vijay Kumar
8051 microcontroller by K. Vijay Kumar
 
Atemega saya
Atemega sayaAtemega saya
Atemega saya
 
Overview of Microcontroller and ATMega32 microcontroller
Overview of Microcontroller and ATMega32 microcontrollerOverview of Microcontroller and ATMega32 microcontroller
Overview of Microcontroller and ATMega32 microcontroller
 
A tmega16A Microcontroller Data Sheet
A tmega16A Microcontroller Data SheetA tmega16A Microcontroller Data Sheet
A tmega16A Microcontroller Data Sheet
 
4th yr dmumicrocontroller1
4th yr dmumicrocontroller14th yr dmumicrocontroller1
4th yr dmumicrocontroller1
 
Avr report
Avr reportAvr report
Avr report
 

More from PallaviHailkar (7)

Fiber Optics Communication Multiple Choice Question.pptx
Fiber Optics Communication Multiple Choice Question.pptxFiber Optics Communication Multiple Choice Question.pptx
Fiber Optics Communication Multiple Choice Question.pptx
 
Chapter4.pptx
Chapter4.pptxChapter4.pptx
Chapter4.pptx
 
Chapter3_Losses.pptx
Chapter3_Losses.pptxChapter3_Losses.pptx
Chapter3_Losses.pptx
 
Interrupt.pptx
Interrupt.pptxInterrupt.pptx
Interrupt.pptx
 
The 8051 microcontroller
The 8051 microcontrollerThe 8051 microcontroller
The 8051 microcontroller
 
Optical sources and detectors
Optical sources and detectorsOptical sources and detectors
Optical sources and detectors
 
Introduction to fiber optics communication
Introduction to fiber optics communicationIntroduction to fiber optics communication
Introduction to fiber optics communication
 

Recently uploaded

Making and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdfMaking and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdf
Chris Hunter
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
heathfieldcps1
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 

Recently uploaded (20)

SECOND SEMESTER TOPIC COVERAGE SY 2023-2024 Trends, Networks, and Critical Th...
SECOND SEMESTER TOPIC COVERAGE SY 2023-2024 Trends, Networks, and Critical Th...SECOND SEMESTER TOPIC COVERAGE SY 2023-2024 Trends, Networks, and Critical Th...
SECOND SEMESTER TOPIC COVERAGE SY 2023-2024 Trends, Networks, and Critical Th...
 
Making and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdfMaking and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdf
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 

8051Architecture_Basics.pptx

  • 1. Presentation By, Mrs. Pallavi Mahagaonkar Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 2. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 3. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar CPU RAM ROM Input/output Timers Serial Com port
  • 4. Have you used Microcontroller ? Please write your Answers in comment box Name any one application Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 5.  Micro- Size is small  Controller- Which controls the operations  Microcontroller is small size device which is used to perform and control operations Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 6. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 7. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 8. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 9. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 10. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 11. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 12. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 13.  Identify what are the features of this Smart watch? Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 14. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 15. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 16. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 17. From next slide please identify Microcontroller Applications And Write your answers in comment section Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 18. Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 19.  Home Appliances  Intercom  Telephone  TVs  VCR  Cable TV tuner  Remote Controls  Toys  Microwave  Lightening Controls  Video Games Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 20.  Telephones  Copy Machine  Paging  Fax Machine  Security Systems  Laser Printer Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 21.  4 bit Microcontroller  8 bit Microcontroller  16 bit Microcontroller  32 bit Microcontroller Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 22.  Embedded memory microcontroller: 8051 microcontroller  External memory microcontroller: 8031 microcontroller Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 23.  CISC: CISC is a Complex Instruction Set Computer  RISC: The RISC is stands for Reduced Instruction set Computer Prepared for MIT ACSC by Mrs. Pallavi Mahagaonkar
  • 24.  It is 8 bit microcontroller  4k on chip ROM  128 Bytes of on chip RAM  4 Ports with 32 Input/Output Lines  1 Serial Port  2 Timers/Counter  5 Interrupts
  • 25.  A and B Register  16 Bit Program Counter and DPTR  8 bit Stack Pointer  8 Bit Data bus  16 bit Address bus
  • 26. CPU 8 Bit 5 Interrupts Timer/Counter 0 Timer/Counter 1 4 Ports P0 P1 P2 P3 1 Serial Port 4 K ROM for Program Code 128 bytes RAM Bus Control Unit Oscillator TXD RXD
  • 27.
  • 28. Name Function Internal Address (Hex) A ACCUMULATOR 0E0 B ARITHMETIC 0F0 DPH Addressing External Memory 83 DPL Addressing External Memory 82 IE Interrupt Enable Control 0A8 IP Interrupt Priority 0B8 P0 Input/Output Port 0 Latch 80 P1 Input/Output Port 1 Latch 90 P2 Input/Output Port 2 Latch 0A0 P3 Input/Output Port 3 Latch 0B0 Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
  • 29. Name Function Internal Address (Hex) PCON Power Control 87 PSW Program Status Word 0D0 SCON Serial Port Control 98 SBUF Serial Port Data Buffer 99 SP Stack Pointer 81 TMOD Timer/ Counter Mode Control 89 TCON Timer/ Counter Control 88 TL0 Timer 0 Low Byte 8A TH0 Timer 0 High Byte 8C TL1 Timer 1 Low Byte 8B TH1 Timer 1 High Byte 8D Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
  • 30. Number of Pins Function 2 Vcc and Ground (40 , 20) 2 XTAL1 and XTAL2 (19, 18) 1 Reset (9) 3 PSEN, ALE, EA (29, 30, 31) 32 Input/output Port (P0, P1, P2, P3) 40 Total Prepared By Mrs. Pallavi Mahagaonkarfor MIT ACSC
  • 31.  The 8051 has four important ports P0, P1, P2 and P3  These ports allow the microcontroller to connect with the outside world  Each port has 8 pins. Thus total 32 pins can be used as I/O  All ports are bidirectional  They are constructed with a D type output latch. They have output drivers and input buffers  All the ports are configured as input ports on Reset  To configure ports as an input port 1 must be written to that port  To configure it as an output port 0 must be written to it Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 32. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC https://exploreembedded.com/wiki/1.8051_Architecture
  • 33. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC https://exploreembedded.com/wiki/1.8051_Architecture
  • 34. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC To read 0 from the pin of the microcontroller: Write one to pin. M1 turns OFF Read PIN latch is turned ON External zero grounds the pin https://exploreembedded.com/wiki/1.8051_Architecture
  • 35. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC https://exploreembedded.com/wiki/1.8051_Architecture Write one to pin. M1 turns OFF Read PIN latch is turned ON External vcc appears at the pin
  • 36. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC https://electronicsdesk.com/pin-diagram-and-description-of-8051-microcontroller.html
  • 37.  Port 0 have 8 pins which can be used as Input/ Output  Address: 80H  To configure ports as an input port 1 must be written to that port  To configure it as an output port 0 must be written to it  An external pull-up resistor is needed when Port 0 is defined as an output port  Port 0 is used to access external memory in conjunction with Port 2 Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 38.  Port 1 have 8 pins which can be used as Input/ Output  Address: 90H  To configure ports as an input port 1 must be written to that port  To configure it as an output port 1 must be written to it  An external pull-up resistor is not required when Port 1 is defined as an output port Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 39.  Port 2 have 8 pins which can be used as Input/ Output  Address: A0H  To configure ports as an input port 2 must be written to that port  To configure it as an output port 2 must be written to it  An external pull-up resistor is not required when Port 2 is defined as an output port  Port 2 is used to access external memory in conjunction with Port 0 Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 40.  Port 3 have 8 pins which can be used as Input/ Output  Address: B0H  To configure ports as an input port 3 must be written to that port  To configure it as an output port 3 must be written to it  An external pull-up resistor is not required when Port 3 is defined as an output port  Port 3 have Alternate functions Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 41. RXD: used for a serial input port TXD: used for serial output port INT0: used for an external interrupt 0 INT1: used for external interrupt 1 T0: Timer 0 external input T1: Timer 1 external input WR: external data memory write strobe RD: external data memory Read strobe Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 42. EA: External Access (Input Pin) Ground – Program is Store in External Memory Vcc - Program is stored on On-chip ROM ALE: Address Latch Enable (output pin) 1 - Address 0 - Data PSEN: Program Store Enable It is used to read a signal from the external program memory It should be connected to OE/ CS pin of Memory Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 43. 128x8 128 x 8 Address lines data lines 128=2^7 8 Address lines=7 that is from A0 to A6 Data lines=8 that is from D0 to D7 Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 44. Calculate number of address lines and data lines for 1. 256 x 8 2. 1K x 8 3. 2K x 8 4. 4K x 8 5. 8K x 8 6. 64 x 8 7. 512 x 8 8. 64 k x 8 9. 32K x 8 10. 16 K x 8 Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 45. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC Read Write Memory Chip select Data Bus Address Bus
  • 46. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC Read Write Memory (128x8) Chip select Da ta Bu s Address Bus 8051 Microcontroller
  • 47. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC
  • 48. Prepared By Mrs. Pallavi Mahagaonkar for MIT ACSC