SlideShare a Scribd company logo
1 of 17
Download to read offline
Pari vallal Kannan
Center for Integrated Circuits and Systems
University of Texas at Dallas
8051 Interfacing: Address Map
Generation
EE4380 Fall02
Class 6
12-Sep-02 2
8051 Interfacing
l Address Mapping
– Use address bus and data bus
– Interfaced device show up as memory locations from the
processor
– They use up some of the address space
– Memories, displays etc
l I/O Mapping
– Connect the devices to the I/O Ports of the processor
– Don’t use up address space
– Sensors, pushbuttons, LCDs, motors, LEDs etc
12-Sep-02 3
8051 – Address Generator
l Address Generator is a piece
of hardware that produces
unique addresses to each
interfaced device
l Each Interfaced Device can
use up 1 or more locations
from the address space of the
processor
– Memories typically use up in
Kilobytes (2K, 4K, 8K etc)
– Other devices typically use a
few (<16) addresses
l Addresses of devices should
not overlap
8051
A[15:0]
Addr. Gen
Device 1
Device 2
Device 3
CE
CE
CE
f1
f2
f3
D[7:0]
D[7:0]
D[7:0]
D[7:0]
A[15:0]
A[15:0]
A[15:0]
12-Sep-02 4
What is needed ?
l Need to know the
following for all the
devices before address
generator can be
designed
– Base address of each
device
l Where it starts in the
address map
– Size of the device
l How much of the address
space it uses up
Code Memory Data Memory
0x0000
0x4000
0x1000
0x5000
RAM1 32K
0x0000
0x8000
0xF000
LCD 8b
LEd 2b
Code RAM 4K
Code ROM1 4K
12-Sep-02 5
Example –1 : 2K Memory at 0x0000
l Pins : address - A10 to A0, Data – D7 to D0,
_RD, _WR, _CE
l Base address = 0x0000
l Size = 2k (2 *1024 = 2048 bytes = 0x0800)
l Address Map occupancy
– 0x0000 to 0x07FF that is,
– 0000 - 0000 - 0000 - 0000 binary to
– 0000 - 0111 - 1111 - 1111 binary
l 11 lowest address bits A10 to A0 have to be
connected to the address pins on the memory
12-Sep-02 6
Example –1 : (contd.)
l Unused address bits are
– A15 to A11
l Base address is 0x0000
l CE has to be generated
if all the unused address
bits are logic-0
– CE is active low
l _CE = A15 + A14 + A13
+ A12 + A11
l Then connect _RD and
_WR
0
1
1
1
1
1
0
1
X
X
X
X
0
X
1
X
X
X
0
X
X
1
X
X
0
X
X
X
1
X
0
X
X
X
X
1
_CEA11A12A13A14A15
Truth-Table for CE
12-Sep-02 7
Ex-2: Same Memory at 0x4000
l Base address is 0x4000
– 0100 0000 0000 0000
l Size is 2K
l Unused address bits
– A15 to A11
l CE has to be generated
as per the truth-table
l Expression is
1
0
1
1
1
1
1
1
1
X
0
0
1
0
1
X
0
X
X
1
1
X
0
X
X
X
X
on
0
1
1
1
1
1
so
X
0
X
X
X
X
and
_CEA11A12A13A14A15
1112131415_ AAAAACE ••••=
12-Sep-02 8
(In)Complete Addressing
l Complete addressing:
– Use all unused address bits to generate CE
l Incomplete addressing
– Use a sub-set of the unused address bits
– Used to reduce the address generator complexity
– Produces address aliases (same device at multiple addresses)
l Example
– 2K memory at 0x0000, we used A15 to A11
– Instead just connect A11 to _CE
– Same 2K memory device will then be aliased for all values of
A15 to A12
l 0x0000, 0x1000, 0x2000, 0x3000, …. , 0xF000
– Address generator became very simple, but we lost a lot of
address space
12-Sep-02 9
74138 Decoder for Address Gen.
l 3 to 8 decoder, available in a single
DIP package.
l Takes 3 address lines and
generates complete addressing
among those
l Example
– Connect A15, A14, A13 to the
decoder inputs
– Decoder outputs give base
addresses for
l 0x0000, 0x2000, 0x4000, 0x6000,
0x8000, 0xA000, 0xC000, 0xE000
l For more complicated address
decoding use programmable
devices like PALs, PLDs or FPGAs
C
B
A
G2
G1
Y0
Y1
Y2
Y7
74LS138
A15
A14
A13
GND
Vcc
12-Sep-02 10
External (pure) Code Memory
l Could be RAM or ROM
l Address generation as per standard procedure
l Connect _PSEN to the _OE of the memory
device
l _RD and _WR are ignored
– Don’t connect these 8051 pins to the memory
device
l Connect Data bits D7-D0 of the memory and
the 8051
12-Sep-02 11
External (pure) Data Memory
l Could be RAM or ROM
l Address generation as per standard procedure
l Connect _RD from the 8051 to OE of the
memory
l Connect _WR from the 8051 to WR of the
memory
l Ignore _PSEN
l Connect Data bits D7-D0 of the memory and
the 8051
12-Sep-02 12
External Code + Data Memory
l Could be RAM or ROM
l Address generation as per standard procedure
l Logically AND _PSEN and _RD and then
connect to the OE of the memory
l Connect _WR from the 8051 to WR of the
memory
l Connect Data bits D7-D0 of the memory and
the 8051
12-Sep-02 13
External Non-Memory Devices
l Same procedure as for interfacing memory
l Only difference is that these devices have
smaller sizes and use lesser portions of the
address space
l Example:
– 8 LEDS connected to a 8bit latch. The latch is
address mapped to 0xF000. Size is 1byte
– 8255 I/O device memory mapped at 0xD000. Size is
4 bytes
12-Sep-02 14
Case Study - Sample 8051 System
12-Sep-02 15
Case study – Sample 8051 System
l 8031 based
– No on-chip ROM, 128 bytes on-chip RAM, 18.432MHz oscillator,
74HC373 based ADBUS demuxer
– 8Kx8 external code memory in 28C64 EEPROM
– Code memory at 0x0000
– 32Kx8 external code+data overlapped in 62256 SRAM.
– SRAM mapped at 0x8000
l SRAM and EEPROM share code memory space. So
decoding needed.
– A15 line is used for the purpose
– A15 = 0 è EEPROM is selected (hence 0x0000)
– A15 = 1 è SRAM is selected (hence 0x8000)
l RS232 serial interface available for PC communication
l Monitor programs available
12-Sep-02 16
Reverse Engineering
l Given a system with little or no docs, determine
the function, schematic, etc
l Vendors provide poor support.
l Reverse Engineering is fun !
l Usually No schematics are available
l Software is also undocumented !
l On-chip code could be copy protected !!
12-Sep-02 17
Next Class
l 8051 I/O Mapped interfacing
l 8051 and the 8255 I/O device
l Example – Interfacing a character LCD

More Related Content

What's hot

8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction setSaumitra Rukmangad
 
Microprocessor and Microcontroller Lab Manual!
Microprocessor and Microcontroller Lab Manual!Microprocessor and Microcontroller Lab Manual!
Microprocessor and Microcontroller Lab Manual!PRABHAHARAN429
 
Microprocessor 8085 Chapter 4
Microprocessor 8085 Chapter 4Microprocessor 8085 Chapter 4
Microprocessor 8085 Chapter 4Rishikesh Bhavsar
 
8085 microprocessor Architecture and pin description
8085 microprocessor Architecture and pin description 8085 microprocessor Architecture and pin description
8085 microprocessor Architecture and pin description Vijay Kumar
 
Stacks & subroutines 1
Stacks & subroutines 1Stacks & subroutines 1
Stacks & subroutines 1deval patel
 
8051 basic programming
8051 basic programming8051 basic programming
8051 basic programmingANJUSHA R
 
Architecture of 8085
Architecture of 8085Architecture of 8085
Architecture of 8085Sumit Swain
 
Introduction to 8085 & it's description(includes basic lab experiments)
Introduction to 8085 & it's description(includes basic lab experiments)Introduction to 8085 & it's description(includes basic lab experiments)
Introduction to 8085 & it's description(includes basic lab experiments)Basil John
 
Chapter 6 - Introduction to 8085 Instructions
Chapter 6 - Introduction to 8085 InstructionsChapter 6 - Introduction to 8085 Instructions
Chapter 6 - Introduction to 8085 Instructionscmkandemir
 
Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085Shubham Singh
 
Microprocessor lab manual
Microprocessor lab manualMicroprocessor lab manual
Microprocessor lab manualDhaval Shukla
 

What's hot (20)

8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
 
Class10
Class10Class10
Class10
 
Microprocessor systems 8085(2)
Microprocessor systems 8085(2)Microprocessor systems 8085(2)
Microprocessor systems 8085(2)
 
Microprocessor and Microcontroller Lab Manual!
Microprocessor and Microcontroller Lab Manual!Microprocessor and Microcontroller Lab Manual!
Microprocessor and Microcontroller Lab Manual!
 
8085 microprocessor Embedded system
8085 microprocessor  Embedded system8085 microprocessor  Embedded system
8085 microprocessor Embedded system
 
Microprocessor 8085 Chapter 4
Microprocessor 8085 Chapter 4Microprocessor 8085 Chapter 4
Microprocessor 8085 Chapter 4
 
8085 microprocessor Architecture and pin description
8085 microprocessor Architecture and pin description 8085 microprocessor Architecture and pin description
8085 microprocessor Architecture and pin description
 
Stacks & subroutines 1
Stacks & subroutines 1Stacks & subroutines 1
Stacks & subroutines 1
 
EE2356 Microprocessor and Microcontroller Lab Manuel
EE2356 Microprocessor and Microcontroller Lab ManuelEE2356 Microprocessor and Microcontroller Lab Manuel
EE2356 Microprocessor and Microcontroller Lab Manuel
 
8051 basic programming
8051 basic programming8051 basic programming
8051 basic programming
 
8085 alp programs
8085 alp programs8085 alp programs
8085 alp programs
 
Micro task1
Micro task1Micro task1
Micro task1
 
8085 Architecture
8085 Architecture8085 Architecture
8085 Architecture
 
DIGITAL ELECTRONICS LAB
DIGITAL ELECTRONICS LABDIGITAL ELECTRONICS LAB
DIGITAL ELECTRONICS LAB
 
Architecture of 8085
Architecture of 8085Architecture of 8085
Architecture of 8085
 
Intel 8085 mp
Intel 8085 mpIntel 8085 mp
Intel 8085 mp
 
Introduction to 8085 & it's description(includes basic lab experiments)
Introduction to 8085 & it's description(includes basic lab experiments)Introduction to 8085 & it's description(includes basic lab experiments)
Introduction to 8085 & it's description(includes basic lab experiments)
 
Chapter 6 - Introduction to 8085 Instructions
Chapter 6 - Introduction to 8085 InstructionsChapter 6 - Introduction to 8085 Instructions
Chapter 6 - Introduction to 8085 Instructions
 
Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085
 
Microprocessor lab manual
Microprocessor lab manualMicroprocessor lab manual
Microprocessor lab manual
 

Viewers also liked (7)

Class9
Class9Class9
Class9
 
Class8
Class8Class8
Class8
 
Class5
Class5Class5
Class5
 
Chapter 7 8051 programming in c
Chapter 7  8051 programming in cChapter 7  8051 programming in c
Chapter 7 8051 programming in c
 
Microcontroller 8051 and its interfacing
Microcontroller 8051 and its interfacingMicrocontroller 8051 and its interfacing
Microcontroller 8051 and its interfacing
 
8051 Microcontroller Notes
8051 Microcontroller Notes8051 Microcontroller Notes
8051 Microcontroller Notes
 
Class7
Class7Class7
Class7
 

Similar to Class6

Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1Kshitij Singh
 
Architecture and pin diagram of 8085
Architecture and pin diagram of 8085Architecture and pin diagram of 8085
Architecture and pin diagram of 8085Suchismita Paul
 
8085 microprocessor
8085 microprocessor8085 microprocessor
8085 microprocessorIama Marsian
 
Microprocessor questions converted
Microprocessor questions convertedMicroprocessor questions converted
Microprocessor questions convertedArghodeepPaul
 
2. 8085-Microprocessor.pptx
2. 8085-Microprocessor.pptx2. 8085-Microprocessor.pptx
2. 8085-Microprocessor.pptxISMT College
 
Introduction to embedded system & density based traffic light system
Introduction to embedded system & density based traffic light systemIntroduction to embedded system & density based traffic light system
Introduction to embedded system & density based traffic light systemRani Loganathan
 
8085 microprocessor Architecture and Pin description
8085 microprocessor Architecture and Pin description 8085 microprocessor Architecture and Pin description
8085 microprocessor Architecture and Pin description Vijay Kumar
 
lecture 18PART 1 Memory Interfacing.pptx
lecture 18PART 1  Memory Interfacing.pptxlecture 18PART 1  Memory Interfacing.pptx
lecture 18PART 1 Memory Interfacing.pptx0901ET211047ROHITSIN
 
Bus Structure, Memory and I/O Interfacing
Bus Structure, Memory and I/O InterfacingBus Structure, Memory and I/O Interfacing
Bus Structure, Memory and I/O InterfacingHetauda City College
 
8085-microprocessor
8085-microprocessor8085-microprocessor
8085-microprocessorATTO RATHORE
 
Microprocessorlabmanual ee0310
Microprocessorlabmanual ee0310Microprocessorlabmanual ee0310
Microprocessorlabmanual ee0310DHEERAJ DHAKAR
 
Microprocessor Part 2
Microprocessor    Part 2Microprocessor    Part 2
Microprocessor Part 2Sajan Agrawal
 
Architecture of the Intel 8051 Microcontroller
Architecture of the Intel 8051 MicrocontrollerArchitecture of the Intel 8051 Microcontroller
Architecture of the Intel 8051 MicrocontrollerSudhanshu Janwadkar
 
Ece 8085-microprocessor-ppt
Ece 8085-microprocessor-pptEce 8085-microprocessor-ppt
Ece 8085-microprocessor-pptsatyamshra
 
Embedded systems, 8051 microcontroller
Embedded systems, 8051 microcontrollerEmbedded systems, 8051 microcontroller
Embedded systems, 8051 microcontrollerAmandeep Alag
 

Similar to Class6 (20)

Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1
 
Architecture and pin diagram of 8085
Architecture and pin diagram of 8085Architecture and pin diagram of 8085
Architecture and pin diagram of 8085
 
8085 microprocessor
8085 microprocessor8085 microprocessor
8085 microprocessor
 
Ch3 ppt
Ch3 pptCh3 ppt
Ch3 ppt
 
microprocessor 8085
microprocessor 8085microprocessor 8085
microprocessor 8085
 
Microprocessor questions converted
Microprocessor questions convertedMicroprocessor questions converted
Microprocessor questions converted
 
2. 8085-Microprocessor.pptx
2. 8085-Microprocessor.pptx2. 8085-Microprocessor.pptx
2. 8085-Microprocessor.pptx
 
Introduction to embedded system & density based traffic light system
Introduction to embedded system & density based traffic light systemIntroduction to embedded system & density based traffic light system
Introduction to embedded system & density based traffic light system
 
8085 microprocessor Architecture and Pin description
8085 microprocessor Architecture and Pin description 8085 microprocessor Architecture and Pin description
8085 microprocessor Architecture and Pin description
 
lecture 18PART 1 Memory Interfacing.pptx
lecture 18PART 1  Memory Interfacing.pptxlecture 18PART 1  Memory Interfacing.pptx
lecture 18PART 1 Memory Interfacing.pptx
 
8085 architecture
8085 architecture8085 architecture
8085 architecture
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
 
Bus Structure, Memory and I/O Interfacing
Bus Structure, Memory and I/O InterfacingBus Structure, Memory and I/O Interfacing
Bus Structure, Memory and I/O Interfacing
 
8085-microprocessor
8085-microprocessor8085-microprocessor
8085-microprocessor
 
Microprocessorlabmanual ee0310
Microprocessorlabmanual ee0310Microprocessorlabmanual ee0310
Microprocessorlabmanual ee0310
 
Microprocessor Part 2
Microprocessor    Part 2Microprocessor    Part 2
Microprocessor Part 2
 
Hd44780a00 dtasheet
Hd44780a00 dtasheetHd44780a00 dtasheet
Hd44780a00 dtasheet
 
Architecture of the Intel 8051 Microcontroller
Architecture of the Intel 8051 MicrocontrollerArchitecture of the Intel 8051 Microcontroller
Architecture of the Intel 8051 Microcontroller
 
Ece 8085-microprocessor-ppt
Ece 8085-microprocessor-pptEce 8085-microprocessor-ppt
Ece 8085-microprocessor-ppt
 
Embedded systems, 8051 microcontroller
Embedded systems, 8051 microcontrollerEmbedded systems, 8051 microcontroller
Embedded systems, 8051 microcontroller
 

Recently uploaded

Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdfKamal Acharya
 
Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...Christo Ananth
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)simmis5
 
Thermal Engineering Unit - I & II . ppt
Thermal Engineering  Unit - I & II . pptThermal Engineering  Unit - I & II . ppt
Thermal Engineering Unit - I & II . pptDineshKumar4165
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Bookingroncy bisnoi
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingrknatarajan
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...ranjana rawat
 
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank  Design by Working Stress - IS Method.pdfIntze Overhead Water Tank  Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank Design by Working Stress - IS Method.pdfSuman Jyoti
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...SUHANI PANDEY
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college projectTonystark477637
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdfKamal Acharya
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfKamal Acharya
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Bookingdharasingh5698
 

Recently uploaded (20)

Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdf
 
Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
Thermal Engineering Unit - I & II . ppt
Thermal Engineering  Unit - I & II . pptThermal Engineering  Unit - I & II . ppt
Thermal Engineering Unit - I & II . ppt
 
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
 
NFPA 5000 2024 standard .
NFPA 5000 2024 standard                                  .NFPA 5000 2024 standard                                  .
NFPA 5000 2024 standard .
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
 
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank  Design by Working Stress - IS Method.pdfIntze Overhead Water Tank  Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college project
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 

Class6

  • 1. Pari vallal Kannan Center for Integrated Circuits and Systems University of Texas at Dallas 8051 Interfacing: Address Map Generation EE4380 Fall02 Class 6
  • 2. 12-Sep-02 2 8051 Interfacing l Address Mapping – Use address bus and data bus – Interfaced device show up as memory locations from the processor – They use up some of the address space – Memories, displays etc l I/O Mapping – Connect the devices to the I/O Ports of the processor – Don’t use up address space – Sensors, pushbuttons, LCDs, motors, LEDs etc
  • 3. 12-Sep-02 3 8051 – Address Generator l Address Generator is a piece of hardware that produces unique addresses to each interfaced device l Each Interfaced Device can use up 1 or more locations from the address space of the processor – Memories typically use up in Kilobytes (2K, 4K, 8K etc) – Other devices typically use a few (<16) addresses l Addresses of devices should not overlap 8051 A[15:0] Addr. Gen Device 1 Device 2 Device 3 CE CE CE f1 f2 f3 D[7:0] D[7:0] D[7:0] D[7:0] A[15:0] A[15:0] A[15:0]
  • 4. 12-Sep-02 4 What is needed ? l Need to know the following for all the devices before address generator can be designed – Base address of each device l Where it starts in the address map – Size of the device l How much of the address space it uses up Code Memory Data Memory 0x0000 0x4000 0x1000 0x5000 RAM1 32K 0x0000 0x8000 0xF000 LCD 8b LEd 2b Code RAM 4K Code ROM1 4K
  • 5. 12-Sep-02 5 Example –1 : 2K Memory at 0x0000 l Pins : address - A10 to A0, Data – D7 to D0, _RD, _WR, _CE l Base address = 0x0000 l Size = 2k (2 *1024 = 2048 bytes = 0x0800) l Address Map occupancy – 0x0000 to 0x07FF that is, – 0000 - 0000 - 0000 - 0000 binary to – 0000 - 0111 - 1111 - 1111 binary l 11 lowest address bits A10 to A0 have to be connected to the address pins on the memory
  • 6. 12-Sep-02 6 Example –1 : (contd.) l Unused address bits are – A15 to A11 l Base address is 0x0000 l CE has to be generated if all the unused address bits are logic-0 – CE is active low l _CE = A15 + A14 + A13 + A12 + A11 l Then connect _RD and _WR 0 1 1 1 1 1 0 1 X X X X 0 X 1 X X X 0 X X 1 X X 0 X X X 1 X 0 X X X X 1 _CEA11A12A13A14A15 Truth-Table for CE
  • 7. 12-Sep-02 7 Ex-2: Same Memory at 0x4000 l Base address is 0x4000 – 0100 0000 0000 0000 l Size is 2K l Unused address bits – A15 to A11 l CE has to be generated as per the truth-table l Expression is 1 0 1 1 1 1 1 1 1 X 0 0 1 0 1 X 0 X X 1 1 X 0 X X X X on 0 1 1 1 1 1 so X 0 X X X X and _CEA11A12A13A14A15 1112131415_ AAAAACE ••••=
  • 8. 12-Sep-02 8 (In)Complete Addressing l Complete addressing: – Use all unused address bits to generate CE l Incomplete addressing – Use a sub-set of the unused address bits – Used to reduce the address generator complexity – Produces address aliases (same device at multiple addresses) l Example – 2K memory at 0x0000, we used A15 to A11 – Instead just connect A11 to _CE – Same 2K memory device will then be aliased for all values of A15 to A12 l 0x0000, 0x1000, 0x2000, 0x3000, …. , 0xF000 – Address generator became very simple, but we lost a lot of address space
  • 9. 12-Sep-02 9 74138 Decoder for Address Gen. l 3 to 8 decoder, available in a single DIP package. l Takes 3 address lines and generates complete addressing among those l Example – Connect A15, A14, A13 to the decoder inputs – Decoder outputs give base addresses for l 0x0000, 0x2000, 0x4000, 0x6000, 0x8000, 0xA000, 0xC000, 0xE000 l For more complicated address decoding use programmable devices like PALs, PLDs or FPGAs C B A G2 G1 Y0 Y1 Y2 Y7 74LS138 A15 A14 A13 GND Vcc
  • 10. 12-Sep-02 10 External (pure) Code Memory l Could be RAM or ROM l Address generation as per standard procedure l Connect _PSEN to the _OE of the memory device l _RD and _WR are ignored – Don’t connect these 8051 pins to the memory device l Connect Data bits D7-D0 of the memory and the 8051
  • 11. 12-Sep-02 11 External (pure) Data Memory l Could be RAM or ROM l Address generation as per standard procedure l Connect _RD from the 8051 to OE of the memory l Connect _WR from the 8051 to WR of the memory l Ignore _PSEN l Connect Data bits D7-D0 of the memory and the 8051
  • 12. 12-Sep-02 12 External Code + Data Memory l Could be RAM or ROM l Address generation as per standard procedure l Logically AND _PSEN and _RD and then connect to the OE of the memory l Connect _WR from the 8051 to WR of the memory l Connect Data bits D7-D0 of the memory and the 8051
  • 13. 12-Sep-02 13 External Non-Memory Devices l Same procedure as for interfacing memory l Only difference is that these devices have smaller sizes and use lesser portions of the address space l Example: – 8 LEDS connected to a 8bit latch. The latch is address mapped to 0xF000. Size is 1byte – 8255 I/O device memory mapped at 0xD000. Size is 4 bytes
  • 14. 12-Sep-02 14 Case Study - Sample 8051 System
  • 15. 12-Sep-02 15 Case study – Sample 8051 System l 8031 based – No on-chip ROM, 128 bytes on-chip RAM, 18.432MHz oscillator, 74HC373 based ADBUS demuxer – 8Kx8 external code memory in 28C64 EEPROM – Code memory at 0x0000 – 32Kx8 external code+data overlapped in 62256 SRAM. – SRAM mapped at 0x8000 l SRAM and EEPROM share code memory space. So decoding needed. – A15 line is used for the purpose – A15 = 0 è EEPROM is selected (hence 0x0000) – A15 = 1 è SRAM is selected (hence 0x8000) l RS232 serial interface available for PC communication l Monitor programs available
  • 16. 12-Sep-02 16 Reverse Engineering l Given a system with little or no docs, determine the function, schematic, etc l Vendors provide poor support. l Reverse Engineering is fun ! l Usually No schematics are available l Software is also undocumented ! l On-chip code could be copy protected !!
  • 17. 12-Sep-02 17 Next Class l 8051 I/O Mapped interfacing l 8051 and the 8255 I/O device l Example – Interfacing a character LCD