SlideShare a Scribd company logo
1 of 5
Input/Output Organization 1 Lecture 38
CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT
Overview
 Peripheral Devices
 Input-Output Interface
 Asynchronous Data Transfer
 Modes of Transfer
 Priority Interrupt
 Direct Memory Access
 Input-Output Processor
 Serial Communication
Input/Output Organization 2 Lecture 38
CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT
Parallel Priority Interrupts
Mask
register
INTACK
from CPU
Priority
encoder
I0
I1
I 2
I 3
0
1
2
3
y
x
ISTIEN0
1
2
3
0
0
0
0
0
0
Disk
Printer
Reader
Keyboard
Interrupt register
Enable
Interrupt
to CPU
VAD
to CPU
Bus
Buffer
IEN: Set or Clear by instructions ION or IOF
IST: Represents an unmasked interrupt has occurred. INTACK enables tristate Bus Buffer to load VAD generated
by the Priority Logic
Interrupt Register:
- Each bit is associated with an Interrupt Request from different Interrupt Source - different priority level
- Each bit can be cleared by a program instruction
Mask Register:
- Mask Register is associated with Interrupt Register
- Each bit can be set or cleared by an Instruction
Input/Output Organization 3 Lecture 38
CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT
Priority Encoder
Determines the highest priority interrupt when more than one
interrupts take place
Priority Encoder Truth table
1 d d d
0 1 d d
0 0 1 d
0 0 0 1
0 0 0 0
I0 I1 I2 I3
0 0 1
0 1 1
1 0 1
1 1 1
d d 0
x y IST
x = I0' I1'
y = I0' I1 + I0’ I2’
(IST) = I0 + I1 + I2 + I3
Inputs Outputs
Boolean functions
Input/Output Organization 4 Lecture 38
CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT
Interrupt Cycle
At the end of each Instruction cycle
- CPU checks IEN and IST
- If IEN  IST = 1, CPU -> Interrupt Cycle
SP SP - 1 Decrement stack pointer
M[SP]  PC Push PC into stack
INTACK  1 Enable interrupt acknowledge
PC  VAD Transfer vector address to PC
IEN  0 Disable further interrupts
Go To Fetch to execute the first instruction
in the interrupt service routine
Input/Output Organization 5 Lecture 38
CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT
Initial and Final Operations
JMP PTR
JMP RDR
JMP KBD
JMP DISK0
1
2
3
Program to service
magnetic disk
Program to service
line printer
Program to service
character reader
Program to service
keyboard
DISK
PTR
RDR
KBD
255
256
750
256
750
Stack
Main program
current instr.749
KBD
interrupt
2
VAD=00000011 3
4
Disk
interrupt
5
6
7
8
9 10
11
1
Initial and Final Operations
Each interrupt service routine must have an initial and final set of
operations for controlling the registers in the hardware interrupt system
Initial Sequence
[1] Clear lower level Mask reg. bits
[2] IST <- 0
[3] Save contents of CPU registers
[4] IEN <- 1
[5] Go to Interrupt Service Routine
Final Sequence
[1] IEN <- 0
[2] Restore CPU registers
[3] Clear the bit in the Interrupt Reg
[4] Set lower level Mask reg. bits
[5] Restore return address, IEN <- 1

More Related Content

What's hot

03 top level view of computer function and interconnection.ppt.enc
03 top level view of computer function and interconnection.ppt.enc03 top level view of computer function and interconnection.ppt.enc
03 top level view of computer function and interconnection.ppt.encAnwal Mirza
 
Data transfer and manipulation
Data transfer and manipulationData transfer and manipulation
Data transfer and manipulationSanjeev Patel
 
03. top level view of computer function &amp; interconnection
03. top level view of computer function &amp; interconnection03. top level view of computer function &amp; interconnection
03. top level view of computer function &amp; interconnectionnoman yasin
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operationskdisthere
 
03 top level view of computer function and interconnection
03 top level view of computer function and interconnection03 top level view of computer function and interconnection
03 top level view of computer function and interconnectionSher Shah Merkhel
 
Процессорын архитектур
Процессорын архитектурПроцессорын архитектур
Процессорын архитектурMuuluu
 
Chapter 3 - Top Level View of Computer / Function and Interconection
Chapter 3 - Top Level View of Computer / Function and InterconectionChapter 3 - Top Level View of Computer / Function and Interconection
Chapter 3 - Top Level View of Computer / Function and InterconectionCésar de Souza
 
top level view of computer function and interconnection
top level view of computer function and interconnectiontop level view of computer function and interconnection
top level view of computer function and interconnectionSajid Marwat
 
Control unit-implementation
Control unit-implementationControl unit-implementation
Control unit-implementationWBUTTUTORIALS
 
Computer Organization
Computer OrganizationComputer Organization
Computer Organizationanishgoel
 
Computer Organisation and Architecture
Computer Organisation and ArchitectureComputer Organisation and Architecture
Computer Organisation and ArchitectureSubhasis Dash
 
Data Manipulation
Data ManipulationData Manipulation
Data ManipulationAsfi Bhai
 

What's hot (20)

Lecture 11
Lecture 11Lecture 11
Lecture 11
 
Lecture 20
Lecture 20Lecture 20
Lecture 20
 
03 top level view of computer function and interconnection.ppt.enc
03 top level view of computer function and interconnection.ppt.enc03 top level view of computer function and interconnection.ppt.enc
03 top level view of computer function and interconnection.ppt.enc
 
Data transfer and manipulation
Data transfer and manipulationData transfer and manipulation
Data transfer and manipulation
 
Lecture 25
Lecture 25Lecture 25
Lecture 25
 
03. top level view of computer function &amp; interconnection
03. top level view of computer function &amp; interconnection03. top level view of computer function &amp; interconnection
03. top level view of computer function &amp; interconnection
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operations
 
03 top level view of computer function and interconnection
03 top level view of computer function and interconnection03 top level view of computer function and interconnection
03 top level view of computer function and interconnection
 
Процессорын архитектур
Процессорын архитектурПроцессорын архитектур
Процессорын архитектур
 
Chapter 3 - Top Level View of Computer / Function and Interconection
Chapter 3 - Top Level View of Computer / Function and InterconectionChapter 3 - Top Level View of Computer / Function and Interconection
Chapter 3 - Top Level View of Computer / Function and Interconection
 
Design a processor
Design a processorDesign a processor
Design a processor
 
Control unit
Control  unitControl  unit
Control unit
 
top level view of computer function and interconnection
top level view of computer function and interconnectiontop level view of computer function and interconnection
top level view of computer function and interconnection
 
Addressing sequencing
Addressing sequencingAddressing sequencing
Addressing sequencing
 
Lecture 14
Lecture 14Lecture 14
Lecture 14
 
Control unit-implementation
Control unit-implementationControl unit-implementation
Control unit-implementation
 
Lecture 24
Lecture 24Lecture 24
Lecture 24
 
Computer Organization
Computer OrganizationComputer Organization
Computer Organization
 
Computer Organisation and Architecture
Computer Organisation and ArchitectureComputer Organisation and Architecture
Computer Organisation and Architecture
 
Data Manipulation
Data ManipulationData Manipulation
Data Manipulation
 

Similar to Lecture 38

Computer organization part 2
Computer organization part 2Computer organization part 2
Computer organization part 2Hhhh85105
 
Basic computer organisation design
Basic computer organisation designBasic computer organisation design
Basic computer organisation designSanjeev Patel
 
Best-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbaiBest-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbaiUnmesh Baile
 
SESI 7 RouterTroubleshooting.pptx
SESI 7 RouterTroubleshooting.pptxSESI 7 RouterTroubleshooting.pptx
SESI 7 RouterTroubleshooting.pptxFirmanAFauzi1
 
Chapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptxChapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptxJanethMedina31
 
Nvidia tegra K1 Presentation
Nvidia tegra K1 PresentationNvidia tegra K1 Presentation
Nvidia tegra K1 PresentationANURAG SEKHSARIA
 
Interrupts on 8086 microprocessor by vijay kumar.k
Interrupts on 8086 microprocessor by vijay kumar.kInterrupts on 8086 microprocessor by vijay kumar.k
Interrupts on 8086 microprocessor by vijay kumar.kVijay Kumar
 
Computer Architecture – An Introduction
Computer Architecture – An IntroductionComputer Architecture – An Introduction
Computer Architecture – An IntroductionDilum Bandara
 
AAME ARM Techcon2013 002v02 Advanced Features
AAME ARM Techcon2013 002v02 Advanced FeaturesAAME ARM Techcon2013 002v02 Advanced Features
AAME ARM Techcon2013 002v02 Advanced FeaturesAnh Dung NGUYEN
 
Processor Specification and Architecture
Processor Specification and Architecture Processor Specification and Architecture
Processor Specification and Architecture Uday Singh
 
PLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
PLC, DCS and PLC vs DCS Presentation by Jitender Singh ShekhawatPLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
PLC, DCS and PLC vs DCS Presentation by Jitender Singh ShekhawatJitender Singh Shekhawat
 
Basics of plc programming
Basics of plc programmingBasics of plc programming
Basics of plc programmingSergio Barrios
 

Similar to Lecture 38 (20)

Computer organization part 2
Computer organization part 2Computer organization part 2
Computer organization part 2
 
Lecture 18
Lecture 18Lecture 18
Lecture 18
 
Basic computer organisation design
Basic computer organisation designBasic computer organisation design
Basic computer organisation design
 
UNIT 2.pptx
UNIT 2.pptxUNIT 2.pptx
UNIT 2.pptx
 
Best-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbaiBest-embedded-corporate-training-in-mumbai
Best-embedded-corporate-training-in-mumbai
 
Interrupts
InterruptsInterrupts
Interrupts
 
SESI 7 RouterTroubleshooting.pptx
SESI 7 RouterTroubleshooting.pptxSESI 7 RouterTroubleshooting.pptx
SESI 7 RouterTroubleshooting.pptx
 
Interrupts.ppt
Interrupts.pptInterrupts.ppt
Interrupts.ppt
 
Chapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptxChapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptx
 
Nvidia tegra K1 Presentation
Nvidia tegra K1 PresentationNvidia tegra K1 Presentation
Nvidia tegra K1 Presentation
 
DPA
DPADPA
DPA
 
Interrupts on 8086 microprocessor by vijay kumar.k
Interrupts on 8086 microprocessor by vijay kumar.kInterrupts on 8086 microprocessor by vijay kumar.k
Interrupts on 8086 microprocessor by vijay kumar.k
 
Computer Architecture – An Introduction
Computer Architecture – An IntroductionComputer Architecture – An Introduction
Computer Architecture – An Introduction
 
Microcontroller part 2
Microcontroller part 2Microcontroller part 2
Microcontroller part 2
 
AAME ARM Techcon2013 002v02 Advanced Features
AAME ARM Techcon2013 002v02 Advanced FeaturesAAME ARM Techcon2013 002v02 Advanced Features
AAME ARM Techcon2013 002v02 Advanced Features
 
Processor Specification and Architecture
Processor Specification and Architecture Processor Specification and Architecture
Processor Specification and Architecture
 
presentation on SCB,DEBUG,RESET of Arm Cortex processor
presentation on SCB,DEBUG,RESET of Arm Cortex processorpresentation on SCB,DEBUG,RESET of Arm Cortex processor
presentation on SCB,DEBUG,RESET of Arm Cortex processor
 
PLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
PLC, DCS and PLC vs DCS Presentation by Jitender Singh ShekhawatPLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
PLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
 
Real time-embedded-system-lec-05
Real time-embedded-system-lec-05Real time-embedded-system-lec-05
Real time-embedded-system-lec-05
 
Basics of plc programming
Basics of plc programmingBasics of plc programming
Basics of plc programming
 

More from RahulRathi94 (17)

Lecture 47
Lecture 47Lecture 47
Lecture 47
 
Lecture 44
Lecture 44Lecture 44
Lecture 44
 
Lecture 43
Lecture 43Lecture 43
Lecture 43
 
Lecture 42
Lecture 42Lecture 42
Lecture 42
 
Lecture 41
Lecture 41Lecture 41
Lecture 41
 
Lecture 40
Lecture 40Lecture 40
Lecture 40
 
Lecture 35
Lecture 35Lecture 35
Lecture 35
 
Lecture 26
Lecture 26Lecture 26
Lecture 26
 
Lecture 23
Lecture 23Lecture 23
Lecture 23
 
Lecture 22
Lecture 22Lecture 22
Lecture 22
 
Lecture 21
Lecture 21Lecture 21
Lecture 21
 
Lecture 19
Lecture 19Lecture 19
Lecture 19
 
Lecture 17
Lecture 17Lecture 17
Lecture 17
 
Lecture 16
Lecture 16Lecture 16
Lecture 16
 
Lecture 15
Lecture 15Lecture 15
Lecture 15
 
Lecture 13
Lecture 13Lecture 13
Lecture 13
 
Lecture 12
Lecture 12Lecture 12
Lecture 12
 

Recently uploaded

Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 

Recently uploaded (20)

Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 

Lecture 38

  • 1. Input/Output Organization 1 Lecture 38 CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT Overview  Peripheral Devices  Input-Output Interface  Asynchronous Data Transfer  Modes of Transfer  Priority Interrupt  Direct Memory Access  Input-Output Processor  Serial Communication
  • 2. Input/Output Organization 2 Lecture 38 CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT Parallel Priority Interrupts Mask register INTACK from CPU Priority encoder I0 I1 I 2 I 3 0 1 2 3 y x ISTIEN0 1 2 3 0 0 0 0 0 0 Disk Printer Reader Keyboard Interrupt register Enable Interrupt to CPU VAD to CPU Bus Buffer IEN: Set or Clear by instructions ION or IOF IST: Represents an unmasked interrupt has occurred. INTACK enables tristate Bus Buffer to load VAD generated by the Priority Logic Interrupt Register: - Each bit is associated with an Interrupt Request from different Interrupt Source - different priority level - Each bit can be cleared by a program instruction Mask Register: - Mask Register is associated with Interrupt Register - Each bit can be set or cleared by an Instruction
  • 3. Input/Output Organization 3 Lecture 38 CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT Priority Encoder Determines the highest priority interrupt when more than one interrupts take place Priority Encoder Truth table 1 d d d 0 1 d d 0 0 1 d 0 0 0 1 0 0 0 0 I0 I1 I2 I3 0 0 1 0 1 1 1 0 1 1 1 1 d d 0 x y IST x = I0' I1' y = I0' I1 + I0’ I2’ (IST) = I0 + I1 + I2 + I3 Inputs Outputs Boolean functions
  • 4. Input/Output Organization 4 Lecture 38 CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT Interrupt Cycle At the end of each Instruction cycle - CPU checks IEN and IST - If IEN  IST = 1, CPU -> Interrupt Cycle SP SP - 1 Decrement stack pointer M[SP]  PC Push PC into stack INTACK  1 Enable interrupt acknowledge PC  VAD Transfer vector address to PC IEN  0 Disable further interrupts Go To Fetch to execute the first instruction in the interrupt service routine
  • 5. Input/Output Organization 5 Lecture 38 CSE 211, Computer Organization and Architecture Harjeet Kaur, CSE/IT Initial and Final Operations JMP PTR JMP RDR JMP KBD JMP DISK0 1 2 3 Program to service magnetic disk Program to service line printer Program to service character reader Program to service keyboard DISK PTR RDR KBD 255 256 750 256 750 Stack Main program current instr.749 KBD interrupt 2 VAD=00000011 3 4 Disk interrupt 5 6 7 8 9 10 11 1 Initial and Final Operations Each interrupt service routine must have an initial and final set of operations for controlling the registers in the hardware interrupt system Initial Sequence [1] Clear lower level Mask reg. bits [2] IST <- 0 [3] Save contents of CPU registers [4] IEN <- 1 [5] Go to Interrupt Service Routine Final Sequence [1] IEN <- 0 [2] Restore CPU registers [3] Clear the bit in the Interrupt Reg [4] Set lower level Mask reg. bits [5] Restore return address, IEN <- 1