SlideShare a Scribd company logo
- ‘n’ data lines between I/O device and the MPU, all bits
transferred simultaneously.
- fast: ‘n’ bits/clock
- complex implementation, since, at least ‘n’ wires are required.
- Used preferably for short distance high data rate communication
- For long distance communication, ‘n’ amplifiers on ‘n’ data lines,
plus ‘n’ times excess cable length would increase cost ‘n’ times
TRANSMITTER
RECEIVER
D0
D1
D2
D3
D4
D5
D6
D7
 Simple I/O: No signalling is required, as the I/O device is always
available to send/receive. Nature of data is continuos.
e.g: LED connected to an o/p port; Display devices;
 Simple Strobed I/O: Valid data must be indicated with an
accompanying strobe signal. Nature of data is intermittent.
e.g: A keyboard; ADC
 Single Handshaking: Receiver must
confirm with a single
acknowledgement [ACK], so that
transmitter can proceed with the
next data. Nature of data is
essential which should not be lost
or corrupted during transmission.
 Double Handshaking: Used when
the receiver device is not always
ready to receive. The sequence of
events are
- STB low: to query the receiver
- ACK high: Receiver ready
- Data transfer, STB high
- ACK low: Read complete
- Next cycle
 8255 is a low cost TTL compatible parallel
interfacing device
Few 82C55[CMOS version]/8255 specifications
Sink Current: 2.5mA
Max Current: 4.0mA
Speed: 8MHz
 Three ports programmable in two groups:
Group A: PA0-PA7; PC4-PC7
Group B: PB0-PB7; PC0-PC3
 The 8255 is selected at four I/O addresses. In the
PC, 8255 or its equivalent is selected at 60h-63h.
Mode 0 [Basic Input/ Output]
 “No handshaking” required
 Input port is simple buffered input and output port is simple latched output
 Two 8-bit ports: Port A, Port B
 Two 4-bit ports: PC0-PC3, PC4-PC7
Mode 2 [Strobed Bidirectional bus]
 Single handshaking or double handshaking can be implemented with
software
 Bi-directional Data port: Port A 5-bit Data/Control port: Port C
Mode 1 [Strobed Input/ Output]
 Latched input/ output
 Used at the input port with slower peripherals OR at the output port, when
the CPU has to only occasionally send data
 Single handshaking or double handshaking can be implemented with
software
 Data port: Port A Data/Control port: PC4-PC7
Data port: Port B Data/Control port: PC0-PC3
 RESET resets all ports to simple input
ports, mode 0 operation.
 To program the 8255, a command byte
needs to be OUT to the port address
corresponding to the command register
 MSB distinguishes between
Command byte A and B
 Command byte B is used to set/reset
port C bits individually (Bit Set Reset
Mode)
Example 1:
Q. Write a program to read DIP switches
and display accordingly the LEDs.
Soln:
To read DIP switches, port A
must be simple input port and to light the
LEDs, port B must be simple output port.
The necessary control word is
1 0 0 1 x 0 0 x 90h
Let 8255 addresses be 60h-63h. The program is:
; program 8255
MVI A,90h ; control word
OUT 63h ; OUT to control register
; begin I/O
IN 60H ; read port A to accumulator
OUT 61h ; OUT to port B from accumulator
RET
Example: 2
Q. Write a program to set then reset PC7 till PC0 each after 1 second.
Soln: The following will be the BSR control words to set/ reset each bit of port C
Port C will be independent input/output port in mode 0 only. Hence, the
necessary control word to program the 8255 will be
1 0 0 0 0 0 0 0 80h
The program segment is
 New valid data is latched at input port from device.
 STB signal is lowered by the device, as an indicator to the 8255 of valid data.
 IBF is raised by the 8255 indicating that port contains data.
 INTR requested by 8255 to the microprocessor.
 Microprocessor issues an I/O RD, as per priority.
 8255 acknowledges to microprocessor lowering INTR flag.
 8255 lowers IBF indicating that port is empty
Example 3:
Write a subroutine to read
character from keyboard
and print character.
Soln:
Port A is used in mode 1
strobed input to read
character from keyboard.
Port B is used in mode 1
strobed output to print
character. The control word
to program the 8255 is
1011x10x (B4h).
PC4 must be read to check when a key is pressed (Polled I/O), or
interrupt can be enabled (Interrupt-driven). To enable INTEA, set PC4. The BSR
control word is 0xxx1001 (09h).
To print a character, OBFB must be checked for not full (not zero), then
the character can be sent. To read PC1, read port C, and AND with bit pattern
00000010 (02h) (mask all bits except PC1).
Let the addresses be FCh-FFh. The program is
2.instrumentation ii
2.instrumentation ii
2.instrumentation ii

More Related Content

What's hot

Mechatronics ME8791
Mechatronics ME8791 Mechatronics ME8791
Mechatronics ME8791
DrPETERPRAKASH
 
Accessing I/O Devices
Accessing I/O DevicesAccessing I/O Devices
Accessing I/O DevicesSlideshare
 
Microprocessor Presentation
Microprocessor PresentationMicroprocessor Presentation
Microprocessor Presentation
alaminmasum1
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operationskdisthere
 
Input output organisation
Input output organisationInput output organisation
Input output organisation
Sanjeev Patel
 
Microprocessor and Microcontroller lec1
Microprocessor and Microcontroller lec1Microprocessor and Microcontroller lec1
Microprocessor and Microcontroller lec1
Ameen San
 
Introduction to-microprocessors
Introduction to-microprocessorsIntroduction to-microprocessors
Introduction to-microprocessors
Volodymyr Ushenko
 
8085 microprocessor architecture ppt
8085 microprocessor architecture ppt8085 microprocessor architecture ppt
8085 microprocessor architecture pptParvesh Gautam
 
Unit 1 MPMC
Unit 1 MPMCUnit 1 MPMC
Unit 1 MPMC
tamilnesaner
 
Computer oganization input-output
Computer oganization input-outputComputer oganization input-output
Computer oganization input-output
Deepak John
 
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
Mohanumar S
 
Microprocessor and Microcontroller lec2
Microprocessor and Microcontroller lec2Microprocessor and Microcontroller lec2
Microprocessor and Microcontroller lec2
Ameen San
 
Microprocessor & Micro-controller
Microprocessor & Micro-controllerMicroprocessor & Micro-controller
Microprocessor & Micro-controller
Om Bheda
 
3.programmable interrupt controller 8259
3.programmable interrupt controller 82593.programmable interrupt controller 8259
3.programmable interrupt controller 8259
MdFazleRabbi18
 
itft-8085 microprocessor
itft-8085 microprocessoritft-8085 microprocessor
itft-8085 microprocessorShifali Sharma
 
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Mohanumar S
 
Data transfer techniques 8085
Data transfer techniques 8085Data transfer techniques 8085
Data transfer techniques 8085
ShivamSood22
 
microprocessor architecture
microprocessor architecture microprocessor architecture
microprocessor architecture
Nadeem Hilal Wani
 
Architecture of 8085 microprocessor
Architecture of 8085 microprocessorArchitecture of 8085 microprocessor
Architecture of 8085 microprocessor
AMAN SRIVASTAVA
 

What's hot (20)

Mechatronics ME8791
Mechatronics ME8791 Mechatronics ME8791
Mechatronics ME8791
 
Accessing I/O Devices
Accessing I/O DevicesAccessing I/O Devices
Accessing I/O Devices
 
Microprocessor Presentation
Microprocessor PresentationMicroprocessor Presentation
Microprocessor Presentation
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operations
 
Input output organisation
Input output organisationInput output organisation
Input output organisation
 
Microprocessor and Microcontroller lec1
Microprocessor and Microcontroller lec1Microprocessor and Microcontroller lec1
Microprocessor and Microcontroller lec1
 
Introduction to-microprocessors
Introduction to-microprocessorsIntroduction to-microprocessors
Introduction to-microprocessors
 
8085 microprocessor architecture ppt
8085 microprocessor architecture ppt8085 microprocessor architecture ppt
8085 microprocessor architecture ppt
 
Unit 1 MPMC
Unit 1 MPMCUnit 1 MPMC
Unit 1 MPMC
 
Microprocessor
MicroprocessorMicroprocessor
Microprocessor
 
Computer oganization input-output
Computer oganization input-outputComputer oganization input-output
Computer oganization input-output
 
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
Unit 4-PROGRAMMABLE LOGIC INTERFACE-ME6702– MECHATRONICS
 
Microprocessor and Microcontroller lec2
Microprocessor and Microcontroller lec2Microprocessor and Microcontroller lec2
Microprocessor and Microcontroller lec2
 
Microprocessor & Micro-controller
Microprocessor & Micro-controllerMicroprocessor & Micro-controller
Microprocessor & Micro-controller
 
3.programmable interrupt controller 8259
3.programmable interrupt controller 82593.programmable interrupt controller 8259
3.programmable interrupt controller 8259
 
itft-8085 microprocessor
itft-8085 microprocessoritft-8085 microprocessor
itft-8085 microprocessor
 
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
 
Data transfer techniques 8085
Data transfer techniques 8085Data transfer techniques 8085
Data transfer techniques 8085
 
microprocessor architecture
microprocessor architecture microprocessor architecture
microprocessor architecture
 
Architecture of 8085 microprocessor
Architecture of 8085 microprocessorArchitecture of 8085 microprocessor
Architecture of 8085 microprocessor
 

Similar to 2.instrumentation ii

Mod-2 M&M.pptx
Mod-2 M&M.pptxMod-2 M&M.pptx
Mod-2 M&M.pptx
TechCook1
 
Unit 3-1 (1)
Unit 3-1 (1)Unit 3-1 (1)
Unit 3-1 (1)
Vasu Ch
 
8255 PPI
8255 PPI8255 PPI
8255 PPI
deval patel
 
8255 ppi students material for ppi mpmc study
8255 ppi students material for ppi mpmc study8255 ppi students material for ppi mpmc study
8255 ppi students material for ppi mpmc study
Sirisha Vamsi
 
unit-3-8255.pdf
unit-3-8255.pdfunit-3-8255.pdf
unit-3-8255.pdf
ShanmukhSaiR
 
Unit iii microcontrollers final1
Unit iii microcontrollers final1Unit iii microcontrollers final1
Unit iii microcontrollers final1
Saritha Reddy
 
8255 presentaion.ppt
8255 presentaion.ppt8255 presentaion.ppt
8255 presentaion.ppt
kamlesh deshmukh
 
8255 ppi
8255 ppi8255 ppi
8255 ppi
Suraj Bora
 
8255 ppi.pptx
8255 ppi.pptx8255 ppi.pptx
8255 ppi.pptx
zahid235639
 
8255-PPI MPMC text book for engineering.ppt
8255-PPI MPMC text book for engineering.ppt8255-PPI MPMC text book for engineering.ppt
8255-PPI MPMC text book for engineering.ppt
khushiduppala
 
8255_Ppi new
8255_Ppi new8255_Ppi new
8255_Ppi new
Monica Gunjal
 
Io (2)
Io (2)Io (2)
Io (2)Aisu
 
8155 GPPI
8155 GPPI8155 GPPI
8155 GPPI
deval patel
 
L4-L6 8255 A.pptx
L4-L6 8255 A.pptxL4-L6 8255 A.pptx
L4-L6 8255 A.pptx
Motaleb Hossen Manik
 
I Ointerface in mp
I Ointerface in mpI Ointerface in mp
I Ointerface in mpAisu
 
Bus interface 8086
Bus interface 8086Bus interface 8086
Bus interface 8086
University of Gujrat, Pakistan
 
8255.ppt
8255.ppt8255.ppt
Chapter5
Chapter5Chapter5
Chapter5
Bisrat Girma
 
PPI-MECHATRONICS
PPI-MECHATRONICSPPI-MECHATRONICS
PPI-MECHATRONICS
selvakumar948
 
The 8255 PPI
The 8255 PPIThe 8255 PPI
The 8255 PPI
Srikrishna Thota
 

Similar to 2.instrumentation ii (20)

Mod-2 M&M.pptx
Mod-2 M&M.pptxMod-2 M&M.pptx
Mod-2 M&M.pptx
 
Unit 3-1 (1)
Unit 3-1 (1)Unit 3-1 (1)
Unit 3-1 (1)
 
8255 PPI
8255 PPI8255 PPI
8255 PPI
 
8255 ppi students material for ppi mpmc study
8255 ppi students material for ppi mpmc study8255 ppi students material for ppi mpmc study
8255 ppi students material for ppi mpmc study
 
unit-3-8255.pdf
unit-3-8255.pdfunit-3-8255.pdf
unit-3-8255.pdf
 
Unit iii microcontrollers final1
Unit iii microcontrollers final1Unit iii microcontrollers final1
Unit iii microcontrollers final1
 
8255 presentaion.ppt
8255 presentaion.ppt8255 presentaion.ppt
8255 presentaion.ppt
 
8255 ppi
8255 ppi8255 ppi
8255 ppi
 
8255 ppi.pptx
8255 ppi.pptx8255 ppi.pptx
8255 ppi.pptx
 
8255-PPI MPMC text book for engineering.ppt
8255-PPI MPMC text book for engineering.ppt8255-PPI MPMC text book for engineering.ppt
8255-PPI MPMC text book for engineering.ppt
 
8255_Ppi new
8255_Ppi new8255_Ppi new
8255_Ppi new
 
Io (2)
Io (2)Io (2)
Io (2)
 
8155 GPPI
8155 GPPI8155 GPPI
8155 GPPI
 
L4-L6 8255 A.pptx
L4-L6 8255 A.pptxL4-L6 8255 A.pptx
L4-L6 8255 A.pptx
 
I Ointerface in mp
I Ointerface in mpI Ointerface in mp
I Ointerface in mp
 
Bus interface 8086
Bus interface 8086Bus interface 8086
Bus interface 8086
 
8255.ppt
8255.ppt8255.ppt
8255.ppt
 
Chapter5
Chapter5Chapter5
Chapter5
 
PPI-MECHATRONICS
PPI-MECHATRONICSPPI-MECHATRONICS
PPI-MECHATRONICS
 
The 8255 PPI
The 8255 PPIThe 8255 PPI
The 8255 PPI
 

Recently uploaded

The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
Pipe Restoration Solutions
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
power quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptxpower quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptx
ViniHema
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
BrazilAccount1
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
Osamah Alsalih
 
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang,  ICLR 2024, MLILAB, KAIST AI.pdfJ.Yang,  ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
SamSarthak3
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
Jayaprasanna4
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Sreedhar Chowdam
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
BrazilAccount1
 
Runway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptxRunway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptx
SupreethSP4
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
Jayaprasanna4
 
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
fxintegritypublishin
 
Architectural Portfolio Sean Lockwood
Architectural Portfolio Sean LockwoodArchitectural Portfolio Sean Lockwood
Architectural Portfolio Sean Lockwood
seandesed
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
Kamal Acharya
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
Amil Baba Dawood bangali
 

Recently uploaded (20)

The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
 
power quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptxpower quality voltage fluctuation UNIT - I.pptx
power quality voltage fluctuation UNIT - I.pptx
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
 
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang,  ICLR 2024, MLILAB, KAIST AI.pdfJ.Yang,  ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
 
Runway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptxRunway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptx
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
 
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
 
Architectural Portfolio Sean Lockwood
Architectural Portfolio Sean LockwoodArchitectural Portfolio Sean Lockwood
Architectural Portfolio Sean Lockwood
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
 

2.instrumentation ii

  • 1. - ‘n’ data lines between I/O device and the MPU, all bits transferred simultaneously. - fast: ‘n’ bits/clock - complex implementation, since, at least ‘n’ wires are required. - Used preferably for short distance high data rate communication - For long distance communication, ‘n’ amplifiers on ‘n’ data lines, plus ‘n’ times excess cable length would increase cost ‘n’ times TRANSMITTER RECEIVER D0 D1 D2 D3 D4 D5 D6 D7
  • 2.  Simple I/O: No signalling is required, as the I/O device is always available to send/receive. Nature of data is continuos. e.g: LED connected to an o/p port; Display devices;  Simple Strobed I/O: Valid data must be indicated with an accompanying strobe signal. Nature of data is intermittent. e.g: A keyboard; ADC
  • 3.  Single Handshaking: Receiver must confirm with a single acknowledgement [ACK], so that transmitter can proceed with the next data. Nature of data is essential which should not be lost or corrupted during transmission.  Double Handshaking: Used when the receiver device is not always ready to receive. The sequence of events are - STB low: to query the receiver - ACK high: Receiver ready - Data transfer, STB high - ACK low: Read complete - Next cycle
  • 4.  8255 is a low cost TTL compatible parallel interfacing device Few 82C55[CMOS version]/8255 specifications Sink Current: 2.5mA Max Current: 4.0mA Speed: 8MHz  Three ports programmable in two groups: Group A: PA0-PA7; PC4-PC7 Group B: PB0-PB7; PC0-PC3  The 8255 is selected at four I/O addresses. In the PC, 8255 or its equivalent is selected at 60h-63h.
  • 5.
  • 6. Mode 0 [Basic Input/ Output]  “No handshaking” required  Input port is simple buffered input and output port is simple latched output  Two 8-bit ports: Port A, Port B  Two 4-bit ports: PC0-PC3, PC4-PC7 Mode 2 [Strobed Bidirectional bus]  Single handshaking or double handshaking can be implemented with software  Bi-directional Data port: Port A 5-bit Data/Control port: Port C Mode 1 [Strobed Input/ Output]  Latched input/ output  Used at the input port with slower peripherals OR at the output port, when the CPU has to only occasionally send data  Single handshaking or double handshaking can be implemented with software  Data port: Port A Data/Control port: PC4-PC7 Data port: Port B Data/Control port: PC0-PC3
  • 7.  RESET resets all ports to simple input ports, mode 0 operation.  To program the 8255, a command byte needs to be OUT to the port address corresponding to the command register  MSB distinguishes between Command byte A and B  Command byte B is used to set/reset port C bits individually (Bit Set Reset Mode)
  • 8. Example 1: Q. Write a program to read DIP switches and display accordingly the LEDs. Soln: To read DIP switches, port A must be simple input port and to light the LEDs, port B must be simple output port. The necessary control word is 1 0 0 1 x 0 0 x 90h Let 8255 addresses be 60h-63h. The program is: ; program 8255 MVI A,90h ; control word OUT 63h ; OUT to control register ; begin I/O IN 60H ; read port A to accumulator OUT 61h ; OUT to port B from accumulator RET
  • 9. Example: 2 Q. Write a program to set then reset PC7 till PC0 each after 1 second. Soln: The following will be the BSR control words to set/ reset each bit of port C
  • 10. Port C will be independent input/output port in mode 0 only. Hence, the necessary control word to program the 8255 will be 1 0 0 0 0 0 0 0 80h The program segment is
  • 11.
  • 12.  New valid data is latched at input port from device.  STB signal is lowered by the device, as an indicator to the 8255 of valid data.  IBF is raised by the 8255 indicating that port contains data.  INTR requested by 8255 to the microprocessor.  Microprocessor issues an I/O RD, as per priority.  8255 acknowledges to microprocessor lowering INTR flag.  8255 lowers IBF indicating that port is empty
  • 13.
  • 14.
  • 15. Example 3: Write a subroutine to read character from keyboard and print character. Soln: Port A is used in mode 1 strobed input to read character from keyboard. Port B is used in mode 1 strobed output to print character. The control word to program the 8255 is 1011x10x (B4h). PC4 must be read to check when a key is pressed (Polled I/O), or interrupt can be enabled (Interrupt-driven). To enable INTEA, set PC4. The BSR control word is 0xxx1001 (09h). To print a character, OBFB must be checked for not full (not zero), then the character can be sent. To read PC1, read port C, and AND with bit pattern 00000010 (02h) (mask all bits except PC1). Let the addresses be FCh-FFh. The program is