Input Output Organization

K
Kamal AcharyaSelf Employed
IO Interface
Modes of transfer
Interrupt
Direct Memory Access
Introduction to IO Processor
Input Output Organization
IO Interface
 IO interface provides a method for transferring
information between internal storage and external
I/O devices.
 I/O devices can not directly communicate with the
CPU due to various differences between them.
 The major differences are:
Input Output Organization
I/O Bus and Interface Modules
 I/O bus is attached to all peripherals.
 Interface monitors the address on address bus.
 If it find its own address, it activates path between
bus line and device.
 All the other devices are disabled by their interfaces.
 Data to read or write is made available in the data
bus.
 IO command is made available in the control bus.
 There are four types of IO command:
 Control Command
 Status Command
 Output Data Command
 Input Data Command
IO versus Memory bus
 Like IO bus Memory bus also contain data, address
and control lines.
 There are 3 ways in which computer bus
communicates with memory and IO.
 In the first method, CPU has independent set of
buses for both memory and IO. It is done in
computers that has separate IOP and CPU.
 In second method computers use common bus to
transfer data between IO or memory and CPU. And
separate read and write lines.
 IO read/write is enabled during IO transfer and
memory read/write is enabled during memory
transfer.
 This configuration isolates all I/O interface address
with the memory address and is referred to as
Isolated IO method.
 In third method same address space is used for both
memory and IO interface. They have only one set of
read and write signals.
 Computer treats interface as being part of the
memory system.
 It assign address for each interface which cannot be
used for memory words.
 This configuration is referred to as memory-
mapped IO.
Modes of transfer
 Data transfer between computer and IO device can
be handle in the following ways:
 Programmed IO
 Interrupt-Initiated IO
 Direct Memory Access(DMA)
Programmed IO
 Each data transfer is initiated by an instruction in
the program.
 CPU stays in the program loop until IO unit indicates
it is ready for the data transfer.
 It is time consuming process since it keeps processor
busy needlessly.
Example of programmed IO
 The transfer of data requires three instructions:
Interrupt Initiated IO
 In this type of IO, computer does not check the flag.
It continue to perform its task.
 Whenever any device wants the attention, it sends
the interrupt signal to the CPU.
 CPU then deviates from what it was doing, store the
return address from PC and branch to the address of
the subroutine.
 There are two ways of choosing the branch address:
 Vectored Interrupt
 Non-vectored Interrupt
 In vectored interrupt the source that interrupt the
CPU provides the branch information. This
information is called interrupt vectored.
 In non-vectored interrupt, the branch address is
assigned to the fixed address in the memory.
Priority Interrupt
 There are number of IO devices attached to the
computer.
 They are all capable of generating the interrupt.
 When the interrupt is generated from more than one
device, priority interrupt system is used to determine
which device is to be serviced first.
 Devices with high speed transfer are given higher
priority and slow devices are given lower priority.
 Establishing the priority can be done in two ways:
 Using Software
 Using Hardware
 A pooling procedure is used to identify highest
priority in software means.
Polling Procedure
 There is one common branch address for all
interrupts.
 Branch address contain the code that polls the
interrupt sources in sequence. The highest priority is
tested first.
 The particular service routine of the highest priority
device is served.
 The disadvantage is that time required to poll them
can exceed the time to serve them in large number of
IO devices.
Using Hardware
 Hardware priority system function as an overall
manager.
 It accepts interrupt request and determine the
priorities.
 To speed up the operation each interrupting devices
has its own interrupt vector.
 No polling is required, all decision are established by
hardware priority interrupt unit.
 It can be established by serial or parallel connection
of interrupt lines.
Serial or Daisy Chaining Priority.
 Device with highest priority is placed first.
 Device that wants the attention send the interrupt
request to the CPU.
 CPU then sends the INTACK signal which is applied
to PI(priority in) of the first device.
 If it had requested the attention, it place its
VAD(vector address) on the bus. And it block the
signal by placing 0 in PO(priority out)
 If not it pass the signal to next device through
PO(priority out) by placing 1.
 This process is continued until appropriate device is
found.
 The device whose PI is 1 and PO is 0 is the device
that send the interrupt request.
Input Output Organization
Parallel Priority Interrupt
 It consist of interrupt register whose bits are set
separately by the interrupting devices.
 Priority is established according to the position of
the bits in the register.
 Mask register is used to provide facility for the
higher priority devices to interrupt when lower
priority device is being serviced or disable all lower
priority devices when higher is being serviced.
 Corresponding interrupt bit and mask bit are ANDed
and applied to priority encoder.
 Priority encoder generates two bits of vector address.
 Another output from it sets IST(interrupt status flip
flop).
Input Output Organization
Input Output Organization
Direct Memory Access(DMA)
 In DMA there is direct communication between
memory and the peripheral devices.
 CPU is idle and has no control over the memory
buses.
 DMA controller uses buses and transfer the data
directly between I/O devices and memory.
Input Output Organization
 BR(Bus Request) signal is used by DMA controller to
request CPU for the buses.
 CPU then places the bus on the high impedance state
which behave like open circuit.
 CPU then activates BG(Bus Grant) signal to
acknowledge BR signal.
 DMA now has full control over the buses and
perform the transfer.
 Transfer can be perform in two ways:
 Burst Transfer
 Cycle Stealing
 In burst transfer, a number of memory word is
transfer in a continuous burst. It is done while
communicating with fast devices and can’t be
stopped or slow down.
 In cycle stealing, one data word is transfer at a time.
 CPU delays it operation for one cycle during which
DMA transfer takes place.
DMA Controller
DMA Controller
 It communicates with CPU through data bus and
control lines.
 Registers in DMA are selected by CPU by enabling
DS and RS.
 RD and WR signals are for read and write operation.
 When BG=0 CPU can communicate with DMA
register for read or write operation.
 When BG=1 DMA communicate directly with the
memory.
DMA Controller
 It has three register: address, word count and control
register.
 Address register contain address which specify the
location of memory to read or write.
 It is incremented after each word is transferred into
memory.
 Word count register holds the number of words to be
transferred.
 It is decremented by one after each word is
transferred into memory and regularly check for
zero.
 Control Register specify the mode of transfer.
 DMA is first initialized by CPU. After that DMA
continue to transfer data.
 CPU initialize the DMA by sending the following
information through the data bus:
 Starting address of memory block for read or write.
 The word count or number of words to read or write.
 Control to specify mode such as read or write.
 Control to start DMA
 Once DMA is initialized, CPU stop communicating
with DMA unless it receive interrupt signal or if it
wants to check how many words has been
transferred.
Input-Output Processor(IOP)
 It is a processor with direct memory access capability
that communicates with IO devices.
 IOP is similar to CPU except that it is designed to
handle the details of IO operation.
 Unlike DMA which is initialized by CPU, IOP can
fetch and execute its own instructions.
 IOP instruction are specially designed to handle IO
operation.
IOP
IOP
 Memory occupies the central position and can
communicate with each processor by DMA.
 CPU is responsible for processing data.
 IOP provides the path for transfer of data between
various peripheral devices and memory.
 Data formats of peripherals differ from CPU and
memory. IOP maintain such problems.
 Data are transfer from IOP to memory by stealing
one memory cycle.
IOP
 Instructions that are read from memory by IOP are
called commands to distinguish them from
instructions that are read by the CPU.
Input Output Organization
1 de 41

Recomendados

Computer architecture input output organization por
Computer architecture input output organizationComputer architecture input output organization
Computer architecture input output organizationMazin Alwaaly
15.8K visualizações43 slides
Input output organization por
Input output organizationInput output organization
Input output organizationabdulugc
49.1K visualizações65 slides
Modes Of Transfer in Input/Output Organization por
Modes Of Transfer in Input/Output OrganizationModes Of Transfer in Input/Output Organization
Modes Of Transfer in Input/Output OrganizationMOHIT AGARWAL
4.6K visualizações12 slides
Stack organization por
Stack organizationStack organization
Stack organizationchauhankapil
14.9K visualizações9 slides
Register organization, stack por
Register organization, stackRegister organization, stack
Register organization, stackAsif Iqbal
12.6K visualizações19 slides
8086 microprocessor-architecture por
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architectureprasadpawaskar
192.1K visualizações30 slides

Mais conteúdo relacionado

Mais procurados

Direct memory access (dma) por
Direct memory access (dma)Direct memory access (dma)
Direct memory access (dma)Zubair Khalid
16.4K visualizações21 slides
Direct memory access por
Direct memory accessDirect memory access
Direct memory accessRoshan kumar sahu
1.3K visualizações14 slides
Microprogrammed Control Unit por
Microprogrammed Control UnitMicroprogrammed Control Unit
Microprogrammed Control UnitPreethiSureshkumar1
19.4K visualizações20 slides
Direct memory access por
Direct memory accessDirect memory access
Direct memory accessshubham kuwar
16.9K visualizações16 slides
Direct Memory Access ppt por
Direct Memory Access pptDirect Memory Access ppt
Direct Memory Access pptOECLIB Odisha Electronics Control Library
10.7K visualizações17 slides
Pipelining and vector processing por
Pipelining and vector processingPipelining and vector processing
Pipelining and vector processingKamal Acharya
63.4K visualizações52 slides

Mais procurados(20)

Direct memory access (dma) por Zubair Khalid
Direct memory access (dma)Direct memory access (dma)
Direct memory access (dma)
Zubair Khalid16.4K visualizações
Direct memory access por Roshan kumar sahu
Direct memory accessDirect memory access
Direct memory access
Roshan kumar sahu1.3K visualizações
Microprogrammed Control Unit por PreethiSureshkumar1
Microprogrammed Control UnitMicroprogrammed Control Unit
Microprogrammed Control Unit
PreethiSureshkumar119.4K visualizações
Direct memory access por shubham kuwar
Direct memory accessDirect memory access
Direct memory access
shubham kuwar16.9K visualizações
Pipelining and vector processing por Kamal Acharya
Pipelining and vector processingPipelining and vector processing
Pipelining and vector processing
Kamal Acharya63.4K visualizações
Computer architecture instruction formats por Mazin Alwaaly
Computer architecture instruction formatsComputer architecture instruction formats
Computer architecture instruction formats
Mazin Alwaaly8K visualizações
DMA and DMA controller por nishant upadhyay
DMA and DMA controllerDMA and DMA controller
DMA and DMA controller
nishant upadhyay10.8K visualizações
DMA operation por Imran Khan
DMA operationDMA operation
DMA operation
Imran Khan25.5K visualizações
Dma por Piyush Rochwani
DmaDma
Dma
Piyush Rochwani5.3K visualizações
Computer registers por DeepikaT13
Computer registersComputer registers
Computer registers
DeepikaT137.5K visualizações
instruction format and addressing modes por RamaPrabha24
instruction format and addressing modesinstruction format and addressing modes
instruction format and addressing modes
RamaPrabha24803 visualizações
Instruction Set Architecture (ISA) por Gaditek
Instruction Set Architecture (ISA)Instruction Set Architecture (ISA)
Instruction Set Architecture (ISA)
Gaditek6.2K visualizações
Memory organization (Computer architecture) por Sandesh Jonchhe
Memory organization (Computer architecture)Memory organization (Computer architecture)
Memory organization (Computer architecture)
Sandesh Jonchhe13K visualizações
Instruction format por Sanjeev Patel
Instruction formatInstruction format
Instruction format
Sanjeev Patel77.1K visualizações
Modes of transfer por Andhra University
Modes of transferModes of transfer
Modes of transfer
Andhra University8.2K visualizações
Io techniques & its types por Nehal Naik
Io techniques & its typesIo techniques & its types
Io techniques & its types
Nehal Naik26.3K visualizações
Bus aribration por Saiyam Agrawal
Bus aribrationBus aribration
Bus aribration
Saiyam Agrawal2.9K visualizações

Similar a Input Output Organization

Unit 4-input-output organization por
Unit 4-input-output organizationUnit 4-input-output organization
Unit 4-input-output organizationvishal choudhary
68 visualizações26 slides
Unit 4-input-output organization por
Unit 4-input-output organizationUnit 4-input-output organization
Unit 4-input-output organizationvishal choudhary
58 visualizações26 slides
inputoutputorganization-140722085906-phpapp01.pptx por
inputoutputorganization-140722085906-phpapp01.pptxinputoutputorganization-140722085906-phpapp01.pptx
inputoutputorganization-140722085906-phpapp01.pptxAshokRachapalli1
1 visão41 slides
Input - output organzation por
Input - output organzationInput - output organzation
Input - output organzationdaxesh chauhan
989 visualizações44 slides
Unit3 input por
Unit3 inputUnit3 input
Unit3 inputAshim Saha
1.2K visualizações30 slides
ch -6 IO.pptx por
ch -6 IO.pptxch -6 IO.pptx
ch -6 IO.pptxGadisaKanchora1
4 visualizações15 slides

Similar a Input Output Organization(20)

Unit 4-input-output organization por vishal choudhary
Unit 4-input-output organizationUnit 4-input-output organization
Unit 4-input-output organization
vishal choudhary68 visualizações
Unit 4-input-output organization por vishal choudhary
Unit 4-input-output organizationUnit 4-input-output organization
Unit 4-input-output organization
vishal choudhary58 visualizações
inputoutputorganization-140722085906-phpapp01.pptx por AshokRachapalli1
inputoutputorganization-140722085906-phpapp01.pptxinputoutputorganization-140722085906-phpapp01.pptx
inputoutputorganization-140722085906-phpapp01.pptx
AshokRachapalli11 visão
Input - output organzation por daxesh chauhan
Input - output organzationInput - output organzation
Input - output organzation
daxesh chauhan989 visualizações
Unit3 input por Ashim Saha
Unit3 inputUnit3 input
Unit3 input
Ashim Saha1.2K visualizações
ch -6 IO.pptx por GadisaKanchora1
ch -6 IO.pptxch -6 IO.pptx
ch -6 IO.pptx
GadisaKanchora14 visualizações
Modes of data transfer.computer architecture. por pratikkadam78
Modes of data transfer.computer architecture. Modes of data transfer.computer architecture.
Modes of data transfer.computer architecture.
pratikkadam78451 visualizações
Input output in computer Orgranization and architecture por vikram patel
Input output in computer Orgranization and architectureInput output in computer Orgranization and architecture
Input output in computer Orgranization and architecture
vikram patel3.2K visualizações
Computer architecture presentation por Muhammad Hamza
Computer architecture presentationComputer architecture presentation
Computer architecture presentation
Muhammad Hamza158 visualizações
Computer function-and-interconnection 3 por Mujaheed Sulantingan
Computer function-and-interconnection 3Computer function-and-interconnection 3
Computer function-and-interconnection 3
Mujaheed Sulantingan2.4K visualizações
Computer function-and-interconnection 3 por Mujaheed Sulantingan
Computer function-and-interconnection 3Computer function-and-interconnection 3
Computer function-and-interconnection 3
Mujaheed Sulantingan6.9K visualizações
Input/Output System (Part 2) por Ajeng Savitri
Input/Output System (Part 2) Input/Output System (Part 2)
Input/Output System (Part 2)
Ajeng Savitri1.5K visualizações
Chap2 comp architecture por raksharao
Chap2 comp architectureChap2 comp architecture
Chap2 comp architecture
raksharao218 visualizações
IO_ORGANIZATION.pdf por GaganaPurshothama
IO_ORGANIZATION.pdfIO_ORGANIZATION.pdf
IO_ORGANIZATION.pdf
GaganaPurshothama13 visualizações
input output organization.pptx por MeenakshiR43
input output organization.pptxinput output organization.pptx
input output organization.pptx
MeenakshiR4316 visualizações
Input output accessing por ankitraosingh
Input output accessingInput output accessing
Input output accessing
ankitraosingh5.1K visualizações
Input output por jyoti_lakhani
Input outputInput output
Input output
jyoti_lakhani1.9K visualizações
COMPUTER ORGANIZATION NOTES Unit 3 4 por Dr.MAYA NAYAK
COMPUTER ORGANIZATION NOTES  Unit 3 4COMPUTER ORGANIZATION NOTES  Unit 3 4
COMPUTER ORGANIZATION NOTES Unit 3 4
Dr.MAYA NAYAK1.5K visualizações

Mais de Kamal Acharya

Programming the basic computer por
Programming the basic computerProgramming the basic computer
Programming the basic computerKamal Acharya
1.3K visualizações76 slides
Computer Arithmetic por
Computer ArithmeticComputer Arithmetic
Computer ArithmeticKamal Acharya
788 visualizações21 slides
Introduction to Computer Security por
Introduction to Computer SecurityIntroduction to Computer Security
Introduction to Computer SecurityKamal Acharya
864 visualizações56 slides
Session and Cookies por
Session and CookiesSession and Cookies
Session and CookiesKamal Acharya
1.2K visualizações19 slides
Functions in php por
Functions in phpFunctions in php
Functions in phpKamal Acharya
937 visualizações48 slides
Web forms in php por
Web forms in phpWeb forms in php
Web forms in phpKamal Acharya
319 visualizações62 slides

Mais de Kamal Acharya(20)

Programming the basic computer por Kamal Acharya
Programming the basic computerProgramming the basic computer
Programming the basic computer
Kamal Acharya1.3K visualizações
Computer Arithmetic por Kamal Acharya
Computer ArithmeticComputer Arithmetic
Computer Arithmetic
Kamal Acharya788 visualizações
Introduction to Computer Security por Kamal Acharya
Introduction to Computer SecurityIntroduction to Computer Security
Introduction to Computer Security
Kamal Acharya864 visualizações
Session and Cookies por Kamal Acharya
Session and CookiesSession and Cookies
Session and Cookies
Kamal Acharya1.2K visualizações
Functions in php por Kamal Acharya
Functions in phpFunctions in php
Functions in php
Kamal Acharya937 visualizações
Web forms in php por Kamal Acharya
Web forms in phpWeb forms in php
Web forms in php
Kamal Acharya319 visualizações
Making decision and repeating in PHP por Kamal Acharya
Making decision and repeating  in PHPMaking decision and repeating  in PHP
Making decision and repeating in PHP
Kamal Acharya308 visualizações
Working with arrays in php por Kamal Acharya
Working with arrays in phpWorking with arrays in php
Working with arrays in php
Kamal Acharya765 visualizações
Text and Numbers (Data Types)in PHP por Kamal Acharya
Text and Numbers (Data Types)in PHPText and Numbers (Data Types)in PHP
Text and Numbers (Data Types)in PHP
Kamal Acharya315 visualizações
Introduction to PHP por Kamal Acharya
Introduction to PHPIntroduction to PHP
Introduction to PHP
Kamal Acharya250 visualizações
Capacity Planning of Data Warehousing por Kamal Acharya
Capacity Planning of Data WarehousingCapacity Planning of Data Warehousing
Capacity Planning of Data Warehousing
Kamal Acharya1.8K visualizações
Data Warehousing por Kamal Acharya
Data WarehousingData Warehousing
Data Warehousing
Kamal Acharya756 visualizações
Search Engines por Kamal Acharya
Search EnginesSearch Engines
Search Engines
Kamal Acharya737 visualizações
Web Mining por Kamal Acharya
Web MiningWeb Mining
Web Mining
Kamal Acharya215 visualizações
Information Privacy and Data Mining por Kamal Acharya
Information Privacy and Data MiningInformation Privacy and Data Mining
Information Privacy and Data Mining
Kamal Acharya513 visualizações
Cluster Analysis por Kamal Acharya
Cluster AnalysisCluster Analysis
Cluster Analysis
Kamal Acharya803 visualizações
Association Analysis in Data Mining por Kamal Acharya
Association Analysis in Data MiningAssociation Analysis in Data Mining
Association Analysis in Data Mining
Kamal Acharya11.7K visualizações
Classification techniques in data mining por Kamal Acharya
Classification techniques in data miningClassification techniques in data mining
Classification techniques in data mining
Kamal Acharya2.9K visualizações
Data Preprocessing por Kamal Acharya
Data PreprocessingData Preprocessing
Data Preprocessing
Kamal Acharya622 visualizações
Introduction to Data Mining and Data Warehousing por Kamal Acharya
Introduction to Data Mining and Data WarehousingIntroduction to Data Mining and Data Warehousing
Introduction to Data Mining and Data Warehousing
Kamal Acharya2.7K visualizações

Último

12.5.23 Poverty and Precarity.pptx por
12.5.23 Poverty and Precarity.pptx12.5.23 Poverty and Precarity.pptx
12.5.23 Poverty and Precarity.pptxmary850239
162 visualizações30 slides
Career Building in AI - Technologies, Trends and Opportunities por
Career Building in AI - Technologies, Trends and OpportunitiesCareer Building in AI - Technologies, Trends and Opportunities
Career Building in AI - Technologies, Trends and OpportunitiesWebStackAcademy
41 visualizações44 slides
BUSINESS ETHICS MODULE 1 UNIT I_A.pdf por
BUSINESS ETHICS MODULE 1 UNIT I_A.pdfBUSINESS ETHICS MODULE 1 UNIT I_A.pdf
BUSINESS ETHICS MODULE 1 UNIT I_A.pdfDr Vijay Vishwakarma
40 visualizações25 slides
Volf work.pdf por
Volf work.pdfVolf work.pdf
Volf work.pdfMariaKenney3
75 visualizações43 slides
StudioX.pptx por
StudioX.pptxStudioX.pptx
StudioX.pptxNikhileshSathyavarap
89 visualizações18 slides
The Accursed House by Émile Gaboriau por
The Accursed House  by Émile GaboriauThe Accursed House  by Émile Gaboriau
The Accursed House by Émile GaboriauDivyaSheta
246 visualizações15 slides

Último(20)

12.5.23 Poverty and Precarity.pptx por mary850239
12.5.23 Poverty and Precarity.pptx12.5.23 Poverty and Precarity.pptx
12.5.23 Poverty and Precarity.pptx
mary850239162 visualizações
Career Building in AI - Technologies, Trends and Opportunities por WebStackAcademy
Career Building in AI - Technologies, Trends and OpportunitiesCareer Building in AI - Technologies, Trends and Opportunities
Career Building in AI - Technologies, Trends and Opportunities
WebStackAcademy41 visualizações
BUSINESS ETHICS MODULE 1 UNIT I_A.pdf por Dr Vijay Vishwakarma
BUSINESS ETHICS MODULE 1 UNIT I_A.pdfBUSINESS ETHICS MODULE 1 UNIT I_A.pdf
BUSINESS ETHICS MODULE 1 UNIT I_A.pdf
Dr Vijay Vishwakarma40 visualizações
Volf work.pdf por MariaKenney3
Volf work.pdfVolf work.pdf
Volf work.pdf
MariaKenney375 visualizações
The Accursed House by Émile Gaboriau por DivyaSheta
The Accursed House  by Émile GaboriauThe Accursed House  by Émile Gaboriau
The Accursed House by Émile Gaboriau
DivyaSheta246 visualizações
Parts of Speech (1).pptx por mhkpreet001
Parts of Speech (1).pptxParts of Speech (1).pptx
Parts of Speech (1).pptx
mhkpreet00143 visualizações
JQUERY.pdf por ArthyR3
JQUERY.pdfJQUERY.pdf
JQUERY.pdf
ArthyR3103 visualizações
DISTILLATION.pptx por Anupkumar Sharma
DISTILLATION.pptxDISTILLATION.pptx
DISTILLATION.pptx
Anupkumar Sharma57 visualizações
Papal.pdf por MariaKenney3
Papal.pdfPapal.pdf
Papal.pdf
MariaKenney357 visualizações
JRN 362 - Lecture Twenty-Three (Epilogue) por Rich Hanley
JRN 362 - Lecture Twenty-Three (Epilogue)JRN 362 - Lecture Twenty-Three (Epilogue)
JRN 362 - Lecture Twenty-Three (Epilogue)
Rich Hanley41 visualizações
MercerJesse2.1Doc.pdf por jessemercerail
MercerJesse2.1Doc.pdfMercerJesse2.1Doc.pdf
MercerJesse2.1Doc.pdf
jessemercerail301 visualizações
Monthly Information Session for MV Asterix (November) por Esquimalt MFRC
Monthly Information Session for MV Asterix (November)Monthly Information Session for MV Asterix (November)
Monthly Information Session for MV Asterix (November)
Esquimalt MFRC98 visualizações
INT-244 Topic 6b Confucianism por S Meyer
INT-244 Topic 6b ConfucianismINT-244 Topic 6b Confucianism
INT-244 Topic 6b Confucianism
S Meyer44 visualizações
NodeJS and ExpressJS.pdf por ArthyR3
NodeJS and ExpressJS.pdfNodeJS and ExpressJS.pdf
NodeJS and ExpressJS.pdf
ArthyR347 visualizações
Retail Store Scavenger Hunt.pptx por jmurphy154
Retail Store Scavenger Hunt.pptxRetail Store Scavenger Hunt.pptx
Retail Store Scavenger Hunt.pptx
jmurphy15452 visualizações

Input Output Organization

  • 1. IO Interface Modes of transfer Interrupt Direct Memory Access Introduction to IO Processor Input Output Organization
  • 2. IO Interface  IO interface provides a method for transferring information between internal storage and external I/O devices.  I/O devices can not directly communicate with the CPU due to various differences between them.  The major differences are:
  • 4. I/O Bus and Interface Modules
  • 5.  I/O bus is attached to all peripherals.  Interface monitors the address on address bus.  If it find its own address, it activates path between bus line and device.  All the other devices are disabled by their interfaces.  Data to read or write is made available in the data bus.  IO command is made available in the control bus.
  • 6.  There are four types of IO command:  Control Command  Status Command  Output Data Command  Input Data Command
  • 7. IO versus Memory bus  Like IO bus Memory bus also contain data, address and control lines.  There are 3 ways in which computer bus communicates with memory and IO.
  • 8.  In the first method, CPU has independent set of buses for both memory and IO. It is done in computers that has separate IOP and CPU.  In second method computers use common bus to transfer data between IO or memory and CPU. And separate read and write lines.  IO read/write is enabled during IO transfer and memory read/write is enabled during memory transfer.
  • 9.  This configuration isolates all I/O interface address with the memory address and is referred to as Isolated IO method.  In third method same address space is used for both memory and IO interface. They have only one set of read and write signals.  Computer treats interface as being part of the memory system.
  • 10.  It assign address for each interface which cannot be used for memory words.  This configuration is referred to as memory- mapped IO.
  • 11. Modes of transfer  Data transfer between computer and IO device can be handle in the following ways:  Programmed IO  Interrupt-Initiated IO  Direct Memory Access(DMA)
  • 12. Programmed IO  Each data transfer is initiated by an instruction in the program.  CPU stays in the program loop until IO unit indicates it is ready for the data transfer.  It is time consuming process since it keeps processor busy needlessly.
  • 14.  The transfer of data requires three instructions:
  • 15. Interrupt Initiated IO  In this type of IO, computer does not check the flag. It continue to perform its task.  Whenever any device wants the attention, it sends the interrupt signal to the CPU.  CPU then deviates from what it was doing, store the return address from PC and branch to the address of the subroutine.
  • 16.  There are two ways of choosing the branch address:  Vectored Interrupt  Non-vectored Interrupt  In vectored interrupt the source that interrupt the CPU provides the branch information. This information is called interrupt vectored.  In non-vectored interrupt, the branch address is assigned to the fixed address in the memory.
  • 17. Priority Interrupt  There are number of IO devices attached to the computer.  They are all capable of generating the interrupt.  When the interrupt is generated from more than one device, priority interrupt system is used to determine which device is to be serviced first.  Devices with high speed transfer are given higher priority and slow devices are given lower priority.
  • 18.  Establishing the priority can be done in two ways:  Using Software  Using Hardware  A pooling procedure is used to identify highest priority in software means.
  • 19. Polling Procedure  There is one common branch address for all interrupts.  Branch address contain the code that polls the interrupt sources in sequence. The highest priority is tested first.  The particular service routine of the highest priority device is served.  The disadvantage is that time required to poll them can exceed the time to serve them in large number of IO devices.
  • 20. Using Hardware  Hardware priority system function as an overall manager.  It accepts interrupt request and determine the priorities.  To speed up the operation each interrupting devices has its own interrupt vector.  No polling is required, all decision are established by hardware priority interrupt unit.  It can be established by serial or parallel connection of interrupt lines.
  • 21. Serial or Daisy Chaining Priority.  Device with highest priority is placed first.  Device that wants the attention send the interrupt request to the CPU.  CPU then sends the INTACK signal which is applied to PI(priority in) of the first device.  If it had requested the attention, it place its VAD(vector address) on the bus. And it block the signal by placing 0 in PO(priority out)
  • 22.  If not it pass the signal to next device through PO(priority out) by placing 1.  This process is continued until appropriate device is found.  The device whose PI is 1 and PO is 0 is the device that send the interrupt request.
  • 24. Parallel Priority Interrupt  It consist of interrupt register whose bits are set separately by the interrupting devices.  Priority is established according to the position of the bits in the register.  Mask register is used to provide facility for the higher priority devices to interrupt when lower priority device is being serviced or disable all lower priority devices when higher is being serviced.
  • 25.  Corresponding interrupt bit and mask bit are ANDed and applied to priority encoder.  Priority encoder generates two bits of vector address.  Another output from it sets IST(interrupt status flip flop).
  • 28. Direct Memory Access(DMA)  In DMA there is direct communication between memory and the peripheral devices.  CPU is idle and has no control over the memory buses.  DMA controller uses buses and transfer the data directly between I/O devices and memory.
  • 30.  BR(Bus Request) signal is used by DMA controller to request CPU for the buses.  CPU then places the bus on the high impedance state which behave like open circuit.  CPU then activates BG(Bus Grant) signal to acknowledge BR signal.  DMA now has full control over the buses and perform the transfer.
  • 31.  Transfer can be perform in two ways:  Burst Transfer  Cycle Stealing  In burst transfer, a number of memory word is transfer in a continuous burst. It is done while communicating with fast devices and can’t be stopped or slow down.  In cycle stealing, one data word is transfer at a time.  CPU delays it operation for one cycle during which DMA transfer takes place.
  • 33. DMA Controller  It communicates with CPU through data bus and control lines.  Registers in DMA are selected by CPU by enabling DS and RS.  RD and WR signals are for read and write operation.  When BG=0 CPU can communicate with DMA register for read or write operation.  When BG=1 DMA communicate directly with the memory.
  • 34. DMA Controller  It has three register: address, word count and control register.  Address register contain address which specify the location of memory to read or write.  It is incremented after each word is transferred into memory.  Word count register holds the number of words to be transferred.  It is decremented by one after each word is transferred into memory and regularly check for zero.
  • 35.  Control Register specify the mode of transfer.  DMA is first initialized by CPU. After that DMA continue to transfer data.  CPU initialize the DMA by sending the following information through the data bus:  Starting address of memory block for read or write.  The word count or number of words to read or write.  Control to specify mode such as read or write.  Control to start DMA
  • 36.  Once DMA is initialized, CPU stop communicating with DMA unless it receive interrupt signal or if it wants to check how many words has been transferred.
  • 37. Input-Output Processor(IOP)  It is a processor with direct memory access capability that communicates with IO devices.  IOP is similar to CPU except that it is designed to handle the details of IO operation.  Unlike DMA which is initialized by CPU, IOP can fetch and execute its own instructions.  IOP instruction are specially designed to handle IO operation.
  • 38. IOP
  • 39. IOP  Memory occupies the central position and can communicate with each processor by DMA.  CPU is responsible for processing data.  IOP provides the path for transfer of data between various peripheral devices and memory.  Data formats of peripherals differ from CPU and memory. IOP maintain such problems.  Data are transfer from IOP to memory by stealing one memory cycle.
  • 40. IOP  Instructions that are read from memory by IOP are called commands to distinguish them from instructions that are read by the CPU.