SlideShare a Scribd company logo
Jin-Fu Li
Department of Electrical Engineering
National Central University
Jungli, Taiwan
Chapter 5Chapter 5
Input/Output OrganizationInput/Output Organization
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 2
Accessing I/O Devices
Interrupts
Direct Memory Access
Buses
Interface Circuits
Standard I/O Interfaces
Outline
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 3
Content Coverage
Main Memory System
Input/Output System
Arithmetic
and
Logic Unit
Operational
Registers
Program
Counter
Control Unit
Data/InstructionAddress
Central Processing Unit (CPU)
Cache
memory
Instruction
Sets
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 4
Accessing I/O Devices
Single-bus structure
The bus enables all the devices connected to it to
exchange information
Typically, the bus consists of three sets of lines used to
carry address, data, and control signals
Each I/O device is assigned a unique set of addresses
Processor Memory
I/O device 1 I/O device n
Bus
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 5
I/O Mapping
Memory mapped I/O
Devices and memory share an address space
I/O looks just like memory read/write
No special commands for I/O
Large selection of memory access commands available
Isolated I/O
Separate address spaces
Need I/O or memory select lines
Special commands for I/O
Limited set
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 6
Memory-Mapped I/O
When I/O devices and the memory share the same
address space, the arrangement is called memory-
mapped I/O
With memory-mapped I/O, any machine instruction that
can access memory can be used to transfer data to or from
an I/O device
Most computer systems use memory-mapped I/O.
Some processors have special IN and OUT instructions to
perform I/O transfers
When building a computer system based on these processors, the
designer has the option of connecting I/O devices to use the
special I/O address space or simply incorporating them as part of
the memory address space
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 7
I/O Interface for an Input Device
The address decoder, the data and status registers,
and the control circuitry required to coordinate
I/O transfers constitute the device’s interface
circuit
Control
circuits
Address
decoder
Data and status
registers
Bus Data lines
Control lines
Input device
Address lines
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 8
I/O Techniques
Programmed
Interrupt driven
Direct Memory Access (DMA)
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 9
Program-Controlled I/O
Consider a simple example of I/O operations
involving a keyboard and a display device in a
computer system. The four registers shown
below are used in the data transfer operations
The two flags KIRQ and DIRQ in STATUS register are
used in conjunction with interrupts
DATAIN
DATAOUT
STATUS SINSOUTKIRQDIRQ
CONTROL KENDEN
7 6 5 4 3 2 1 0
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 10
An Example
Move #LINE, R0 Initialize memory pointer
WAITK TestBit #0,STATUS Test SIN
Branch=0 WAITK Wait for character to be entered
Move DATAIN,R1 Read character
WAITD TestBit #1,STATUS Test SOUT
Branch=0 WAITD Wait for display to become ready
Move R1,DATAOUT Send character to display
Move R1,(R0)+ Store character and advance pointer
Compare #$0D,R1 Check if Carriage Return
Branch=0 WAITK If not, get another character
Move #$0A,DATAOUT Otherwise, send Line Feed
Call PROCESS Call a subroutine to process the
input line
A program that reads one line from the keyboard,
stores it in memory buffer, and echoes it back to the
display
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 11
Program-Controlled I/O
The example described above illustrates program-
controlled I/O, in which the processor repeatedly
checks a status flag to achieve the required
synchronization between the processor and an input
or output device. We say that the processor polls the
devices
There are two other commonly used mechanisms for
implementing I/O operations: interrupts and direct
memory access
Interrupts: synchronization is achieved by having the I/O
device send a special signal over the bus whenever it is
ready for a data transfer operation
Direct memory access: it involves having the device
interface transfer data directly to or from the memory
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 12
Interrupts
To avoid the processor being not performing any
useful computation, a hardware signal called an
interrupt to the processor can do it. At least one
of the bus control lines, called an interrupt-request
line, is usually dedicated for this purpose
An interrupt-service routine usually is needed and
is executed when an interrupt request is issued
On the other hand, the processor must inform the
device that its request has been recognized so
that it may remove its interrupt-request signal.
An interrupt-acknowledge signal serves this
function
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 13
Example
Program 1
COMPUTE routine
Program 2
PRINT routine
Interrupt occurs
here
1
2
i
i+1
M
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 14
Interrupt-Service Routine & Subroutine
Treatment of an interrupt-service routine is very
similar to that of a subroutine
An important departure from the similarity should
be noted
A subroutine performs a function required by the program
from which it is called.
The interrupt-service routine may not have anything in
common with the program being executed at the time the
interrupt request is received. In fact, the two programs
often belong to different users
Before executing the interrupt-service routine, any
information that may be altered during the execution
of that routine must be saved. This information must
be restored before the interrupted program is
resumed
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 15
Interrupt Latency
The information that needs to be saved and restored
typically includes the condition code flags and the
contents of any registers used by both the interrupted
program and the interrupt-service routine
Saving registers also increases the delay between the
time an interrupt request is received and the start of
execution of the interrupt-service routine. The delay
is called interrupt latency
Typically, the processor saves only the contents of
the program counter and the processor status register.
Any additional information that needs to be saved
must be saved by program instruction at the
beginning of the interrupt-service routine and
restored at the end of the routine
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 16
Interrupt Hardware
An equivalent circuit for an open-drain bus used
to implement a common interrupt-request line
INTR
INTR1 INTR2 INTRn
Processor
INTR
R
Vdd
INTR=INTR1+INTR2+…+INTRn
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 17
Handling Multiple Devices
Handling multiple devices gives rise to a number of
questions:
How can the processor recognize the device requesting an
interrupt?
Given that different devices are likely to require different
interrupt-service routines, how can the processor obtain the
starting address of the appropriate routine in each case?
Should a device be allowed to interrupt the processor while
another interrupt is being serviced?
How should two or more simultaneous interrupt request be
handled?
The information needed to determine whether a
device is requesting an interrupt is available in its
status register
When a device raises an interrupt request, it sets to 1 one of
the bits in its status register, which we will call the IRQ bit
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 18
Identify the Interrupting Device
The simplest way to identify the interrupting device
is to have the interrupt-service routine poll all the
I/O devices connected to the bus
The polling scheme is easy to implement. Its main
disadvantage is the time spent interrogating all the devices
A device requesting an interrupt may identify itself
directly to the processor. Then, the processor can
immediately start executing the corresponding
interrupt-service routine. This is called vectored
interrupts
An interrupt request from a high-priority device
should be accepted while the processor is servicing
another request from a lower-priority device
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 19
Interrupt Priority
The processor’s priority is usually encoded in a few
bits of the processor status word. It can be changed
by program instructions that write into the program
status register (PS). These are privileged instructions,
which can be executed only while the processor is
running in the supervisor mode
The processor is in the supervisor mode only when
executing operating system routines. It switches to
the user mode before beginning to execute
application program
An attempt to execute a privileged instruction while
in the user mode leads to a special type of interrupt
called a privilege exception
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 20
Implementation of Interrupt Priority
An example of the implementation of a multiple-
priority schemeProcessor
Device 1 Device 2 Device p
INTA1
INTR1
Priority arbitration
circuit
INTRp
INTAp
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 21
Simultaneous Requests
Consider the problem of simultaneous arrivals of
interrupt requests from two or more devices. The
processor must have some means of deciding
which request to service first
Interrupt priority scheme with daisy chain
Device 1 Device 2 Device n
INTA
INTR
Processor
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 22
Priority Group
Combination of the interrupt priority scheme
with daisy chain and with individual interrupt-
request and interrupt-acknowledge lines
Processor
Priority arbitration
circuit
Device Device Device
INTA1
INTR1
Device Device Device
INTAp
INTRp
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 23
Direct Memory Access
To transfer large blocks of data at high speed, a
special control unit may be provided between an
external device and the main memory, without
continuous intervention by the processor. This
approach is called direct memory access (DMA)
DMA transfers are performed by a control circuit that
is part of the I/O device interface. We refer to this
circuit as a DMA controller.
Since it has to transfer blocks of data, the DMA
controller must increment the memory address for
successive words and keep track of the number of
transfers
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 24
DMA Controller
Although a DMA controller can transfer data
without intervention by the processor, its
operation must be under the control of a program
executed by the processor
An example
31 30 1 0
IRQ
IE
Status and control
Starting address
Word count
Done
R/W
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 25
DMA Controller in a Computer System
Processor
Main
memory
Disk/DMA
controller
System bus
DMA
controller
Printer Keyboard
Disk Disk
Network
Interface
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 26
Memory Access Priority
Memory accesses by the processor and the DMA
controllers are interwoven. Request by DMA devices
for using the bus are always given higher priority
than processor requests.
Among different DMA devices, top priority is given
to high-speed peripherals such as a disk, a high-
speed network interface, etc.
Since the processor originates most memory access
cycles, the DMA controller can be said to “steal”
memory cycles from the processor. Hence, this
interweaving technique is usually called cycle stealing
The DMA controller may transfer a block of data
without interruption. This is called block/burst mode
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 27
Bus Arbitration
A conflict may arise if both the processor and a DMA
controller or two DMA controllers try to use the bus
at the same time to access the main memory. To
resolve this problem, an arbitration procedure on bus
is needed
The device that is allowed to initiate data transfer on
the bus at any given time is called the bus master.
When the current master relinquishes control of the
bus, another device can acquire this status
Bus arbitration is the process by which the next
device to become the bus master take into account
the needs of various devices by establishing a
priority system for gaining access to the bus
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 28
Bus Arbitration
There are two approaches to bus arbitration
Centralized and distributed
In centralized arbitration, a single bus arbiter
performs the required arbitration
In distributed arbitration, all devices participate
in the selection of the next bus master
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 29
Centralized Arbitration
DMA
Controller 1BG1
BBSY
Processor
DMA
Controller 2
BR
BG2
BG1
BG2
BBSY
BR
Processor DMA controller 2 Processor
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 30
Distributed Arbitration
ARB3
ARB2
ARB1
ARB0
Start-Arbitration
Vcc
O.C.
Interface circuit for device A
0 1 0 1 0 1 1 1
Assume that IDs of A and B are 5 and 6.
Also, the code seen by both devices is 0111
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 31
Buses
A bus protocol is the set of rules that govern the
behavior of various devices connected to the bus
as to when to place information on the bus, assert
control signals, and so on
In a synchronous bus, all devices derive timing
information from a common clock line. Equal
spaced pulses on this line define equal time
intervals
In the simplest form of a synchronous bus, each
of these intervals constitutes a bus cycle during
which one data transfer can take place
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 32
A Synchronous Bus Example
t2t1
t0
Bus clock
Address and
command
Data
Bus Cycle
Timing of an input transfer on a synchronous bus
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 33
A Synchronous Bus Example
Detail timing diagram
t2t1
tAM
Bus clock
Address and
command
Data
t1
tAS
tDM
tDS
Data
Address and
command
Seen by slave
Seen by master
Slave send the
requested data
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 34
Input Transfer Using Multiple Clock Cycles
Address
Command
Clock
Data
Slave-ready
1 2 3 4
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 35
Asynchronous Bus
An alternative scheme for controlling data
transfers on the bus is based on the use of a
handshake between the master and slave
Address
and command
Master-ready
Data
Slave-ready
Bus cycle
t0 t1 t2
t3 t4 t5
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 36
Asynchronous Bus
Handshake control of data transfer during an
output operation
Address
and command
Master-ready
Data
Slave-ready
Bus cycle
t0 t1 t2
t3 t4 t5
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 37
Discussion
The choice of a particular design involves trade-offs
among factors such as
Simplicity of the device interface
Ability to accommodate device interfaces that introduce different
amounts of delay
Total time required for bus transfer
Ability to detect errors results from addressing a nonexistent
device or from an interface malfunction
Asynchronous bus
The handshake process eliminates the need for synchronization
of the sender and receiver clock, thus simplifying timing design
Synchronous bus
Clock circuitry must be designed carefully to ensure proper
synchronization, and delays must be kept within strict bounds
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 38
Interface Circuits
Keyboard to processor connection
When a key is pressed, the Valid signal changes from 0
o 1, causing the ASCII code to be loaded into DATAIN
and SIN to be set to 1
The status flag SIN is cleared to 0 when the processor
reads the contents of the DATAIN register
Processor
Encoder
and
Debouncing
circuit
DATAIN
SIN
Input
Interface
Keyboard
switches
Valid
Data
Data
Address
Master-ready
Slave-ready
R/W
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 39
Input Interface Circuit
Address
decoder
Status
flag
Q7 D7
Q0 D0
Slave-
ready
D7
D0
SIN
Keyboard
data
Valid
A31
A1
A0
Read-
data
Read-
status
1
Master-
ready
DATAIN
R/W
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 40
Circuit for the Status Flag Block
Q D
Q
SIN
Read-data
Master-ready
1
Valid
Clear
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 41
Printer to Processor Connection
The interface contains a data register, DATAOUT,
and a status flag, SOUT
The SOUT flag is set to 1 when the printer is ready to accept
another character, and it is cleared to 0 when a new
character is loaded into DATAOUT by the processor
When the printer is ready to accept a character, it asserts its
idle signal
Processor
DATAOUT
SOUT
Output
Interface
Data
Address
Master-ready
Slave-ready
R/W
Printer
Idle
Data
Valid
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 42
Output Interface Circuit
Address
decoder
Handshake
control
D7 Q7
D0 Q0
Slave-
ready
D7
D0
SOUT
Printer
data
Idle
A31
A1
A0
Load-
data
Read-
status
1
Master-
ready
DATAOUT
R/W
D1 D1 Q1
Valid
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 43
A General 8-Bit Parallel Interface
DATAIN
DATAOUT
Data
Direction
Register
D7
D0
P7
P0
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 44
Output Interface Circuit for a Bus Protocol
Address
decoder
Handshake
control
D7 Q7
D0 Q0
D7
D0
SOUT
Printer
data
Idle
A31
A1
A0
Load-
data
Read-
status
R/W
D1 D1 Q1
Valid
Clock
My-
address Timing
Logic
Go
Respond
Go=1
Idle
My-address
DATAOUT
Slave-
ready
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 45
Timing Diagram for an Output Operation
Clock
Address
Data
Go
Slave-ready
R/W
1 2 3
Time
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 46
Serial Port
A serial port is used to connect the processor to
I/O devices that require transmission of data one
bit at a time
The key feature of an interface circuit for a serial
port is that it is capable of communicating in a
bit-serial fashion on the device side and in a bit-
parallel fashion on the bus side
The transformation between the parallel and
serial formats is achieved with shift registers that
have parallel access capability
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 47
A Serial Interface
Input shift register
DATAIN
DATAOUT
Output shift register
Serial input
Serial output
D7
D0
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 48
Standard I/O Interfaces
The processor bus is the bus defined by the signals on the
processor chip itself. Devices that require a very high
speed connection to the processor, such as the main
memory, may be connected directly to this bus
The motherboard usually provides another bus that can
support more devices.
The two buses are interconnected by a circuit, which we
called a bridge, that translates the signals and protocols of
one bus into those of the other
It is impossible to define a uniform standards for the
processor bus. The structure of this bus is closely tied to
the architecture of the processor
The expansion bus is not subject to these limitations, and
therefore it can use a standardized signaling structure
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 49
Peripheral Component Interconnect Bus
Use of a PCI bus in a computer system
Host
Main
memory
Disk
PCI Bus
Printer
Ethernet
interface
PCI
bridge
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 50
PCI Bus
The bus support three independent address spaces:
memory, I/O, and configuration.
The I/O address space is intended for use with
processors, such Pentium, that have a separate I/O
address space.
However, the system designer may choose to use
memory-mapped I/O even when a separate I/O
address space is available
The configuration space is intended to give the PCI
its plug-and-play capability.
A 4-bit command that accompanies the address identifies
which of the three spaces is being used in a given data
transfer operation
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 51
Data Transfer Signals on the PCI Bus
Name
CLK
FRAME#
AD
C/BE#
IRDY#, TRDY#
DEVSEL#
IDSEL#
A 33-MHz or 66MHz clock
Sent by the initiator to indicate the duration of a transaction
32 address/data lines, which may be optionally increased to 64
4 command/byte-enable lines (8 for 64-bit bus)
Initiator-ready and Target-ready signals
A response from the device indicating that it has recognized its
Address and is ready for a data transfer transaction
Initialization Device Select
Function
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 52
A Read Operation on the PCI Bus
CLK
1 2 3 4 5 6 7
Frame#
AD Address #1 #2 #3 #4
C/BE#
IRDY#
TRDY#
DEVSEL#
Cmnd Byte enable
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 53
Universal Serial Bus (USB)
The USB has been designed to meet several key
objectives
Provide a simple, low-cost, and easy to use
interconnection system that overcomes the difficulties
due to the limited number of I/O ports available on a
computer
Accommodate a wide range of data transfer
characteristics for I/O devices, including telephone and
Internet connections
Enhance user convenience through a “plug-and-play”
mode of operation
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 54
USB Structure
A serial transmission format has been chosen for the USB
because a serial bus satisfies the low-cost and flexibility
requirements
Clock and data information are encoded together and
transmitted as a single signal
Hence, there are no limitations on clock frequency or distance
arising from data skew
To accommodate a large number of devices that can be
added or removed at any time, the USB has the tree
structure
Each node of the tree has a device called a hub, which acts as an
intermediate control point between the host and the I/O device
At the root of the tree, a root hub connects the entire tree to the
host computer
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 55
USB Tree Structure
Root
hub
Host Computer
Hub Hub
Hub
I/O
device
I/O
device
I/O
device
I/O
device
I/O
device
I/O
device
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 56
USB Tree Structure
The tree structure enables many devices to be connected
while using only simple point-to-point serial links
Each hub has a number of ports where devices may be
connected, including other hubs
In normal operation, a hub copies a message that it
receives from its upstream connection to all its
downstream ports
As a result, a message sent by the host computer is broadcast to all
I/O devices, but only the addressed device will respond to that
message
A message sent from an I/O device is sent only upstream
towards the root of the tree and is not seen by other
devices
Hence, USB enables the host to communicate with the I/O devices,
but it does not enable these devices to communicate with each
other
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 57
USB Protocols
All information transferred over the USB is
organized in packets, where a packet consists of
one or more bytes of information
The information transferred on the USB can be
divided into two broad categories: control and
data
Control packets perform such tasks as addressing a
device to initiate data transfer, acknowledging that data
have been received correctly, or indicating an error
Data packets carry information that is delivered to a
device. For example, input and output data are
transferred inside data packets

More Related Content

What's hot

Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003
Swathi Veeradhi
 
Computer Organization and Architecture.
Computer Organization and Architecture.Computer Organization and Architecture.
Computer Organization and Architecture.
CS_GDRCST
 
Computer organization & architecture chapter-1
Computer organization & architecture chapter-1Computer organization & architecture chapter-1
Computer organization & architecture chapter-1
Shah Rukh Rayaz
 
Input Output - Computer Architecture
Input Output - Computer ArchitectureInput Output - Computer Architecture
Input Output - Computer Architecture
Maruf Abdullah (Rion)
 
Unit 5 I/O organization
Unit 5   I/O organizationUnit 5   I/O organization
Unit 5 I/O organizationchidabdu
 
Basic Computer Organization and Design
Basic Computer Organization and DesignBasic Computer Organization and Design
Basic Computer Organization and Design
Kamal Acharya
 
Module4
Module4Module4
Module4
cs19club
 
I/O Organization
I/O OrganizationI/O Organization
I/O Organization
Dhaval Bagal
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operationskdisthere
 
Unit – 2
Unit – 2Unit – 2
Unit – 2
techbed
 
Hardware I/O organization
Hardware  I/O organization Hardware  I/O organization
Hardware I/O organization faria_khan
 
Data transfer techniques 8085
Data transfer techniques 8085Data transfer techniques 8085
Data transfer techniques 8085
ShivamSood22
 
Module 5 part1
Module 5 part1Module 5 part1
Module 5 part1
cs19club
 
Computer Architecture – An Introduction
Computer Architecture – An IntroductionComputer Architecture – An Introduction
Computer Architecture – An Introduction
Dilum Bandara
 
Computer organisation
Computer organisationComputer organisation
Computer organisationMohd Arif
 
Computer Organization
Computer OrganizationComputer Organization
Computer Organization
anishgoel
 
Computer oganization input-output
Computer oganization input-outputComputer oganization input-output
Computer oganization input-output
Deepak John
 
Basic computer organization
Basic computer organizationBasic computer organization
Basic computer organization
Nitesh Singh
 
Input Output Organization
Input Output OrganizationInput Output Organization
Input Output Organization
Kamal Acharya
 
Input output accessing
Input output accessingInput output accessing
Input output accessing
ankitraosingh
 

What's hot (20)

Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003
 
Computer Organization and Architecture.
Computer Organization and Architecture.Computer Organization and Architecture.
Computer Organization and Architecture.
 
Computer organization & architecture chapter-1
Computer organization & architecture chapter-1Computer organization & architecture chapter-1
Computer organization & architecture chapter-1
 
Input Output - Computer Architecture
Input Output - Computer ArchitectureInput Output - Computer Architecture
Input Output - Computer Architecture
 
Unit 5 I/O organization
Unit 5   I/O organizationUnit 5   I/O organization
Unit 5 I/O organization
 
Basic Computer Organization and Design
Basic Computer Organization and DesignBasic Computer Organization and Design
Basic Computer Organization and Design
 
Module4
Module4Module4
Module4
 
I/O Organization
I/O OrganizationI/O Organization
I/O Organization
 
Input Output Operations
Input Output OperationsInput Output Operations
Input Output Operations
 
Unit – 2
Unit – 2Unit – 2
Unit – 2
 
Hardware I/O organization
Hardware  I/O organization Hardware  I/O organization
Hardware I/O organization
 
Data transfer techniques 8085
Data transfer techniques 8085Data transfer techniques 8085
Data transfer techniques 8085
 
Module 5 part1
Module 5 part1Module 5 part1
Module 5 part1
 
Computer Architecture – An Introduction
Computer Architecture – An IntroductionComputer Architecture – An Introduction
Computer Architecture – An Introduction
 
Computer organisation
Computer organisationComputer organisation
Computer organisation
 
Computer Organization
Computer OrganizationComputer Organization
Computer Organization
 
Computer oganization input-output
Computer oganization input-outputComputer oganization input-output
Computer oganization input-output
 
Basic computer organization
Basic computer organizationBasic computer organization
Basic computer organization
 
Input Output Organization
Input Output OrganizationInput Output Organization
Input Output Organization
 
Input output accessing
Input output accessingInput output accessing
Input output accessing
 

Similar to Io pro

COA-Unit5-ppt2.pptx
COA-Unit5-ppt2.pptxCOA-Unit5-ppt2.pptx
COA-Unit5-ppt2.pptx
Ruhul Amin
 
Computer organization
Computer organizationComputer organization
Computer organization
Rvishnupriya2
 
IO hardware
IO hardwareIO hardware
IO hardware
sangrampatil81
 
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptxUNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
LeahRachael
 
IO organization.ppt
IO organization.pptIO organization.ppt
IO organization.ppt
DeepaThirumurugan
 
unit-5 ppt.ppt
unit-5 ppt.pptunit-5 ppt.ppt
unit-5 ppt.ppt
SheebaKelvin2
 
Mca admission in india
Mca admission in indiaMca admission in india
Mca admission in india
Edhole.com
 
420214730-15cs34-module-2-pptx.pptx
420214730-15cs34-module-2-pptx.pptx420214730-15cs34-module-2-pptx.pptx
420214730-15cs34-module-2-pptx.pptx
ddscraft123
 
UNIT 2.pptx
UNIT 2.pptxUNIT 2.pptx
UNIT 2.pptx
SeshuSrinivas2
 
chapter7-io organization.pptx
chapter7-io organization.pptxchapter7-io organization.pptx
chapter7-io organization.pptx
gracemann365
 
Operating system- Chapter 1.pptx to study
Operating system- Chapter 1.pptx to studyOperating system- Chapter 1.pptx to study
Operating system- Chapter 1.pptx to study
muhammadalam77863
 
I/O System
I/O SystemI/O System
I/O System
Nagarajan
 
Chapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptxChapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptx
JanethMedina31
 
8555046.ppt
8555046.ppt8555046.ppt
8555046.ppt
ssuser1b065a
 
Top schools in delhi ncr
Top schools in delhi ncrTop schools in delhi ncr
Top schools in delhi ncr
Edhole.com
 
CO--MODULE-1 (b) - Input-Output-Organization.pptx
CO--MODULE-1 (b) - Input-Output-Organization.pptxCO--MODULE-1 (b) - Input-Output-Organization.pptx
CO--MODULE-1 (b) - Input-Output-Organization.pptx
ahmedsalik057
 
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
ರೇಣುಕ ಭುವನ್
 
Iosystemspre final-160922112930
Iosystemspre final-160922112930Iosystemspre final-160922112930
Iosystemspre final-160922112930
marangburu42
 
Bca examination 2015 csa
Bca examination 2015 csaBca examination 2015 csa
Bca examination 2015 csa
Anjaan Gajendra
 
Microprocessor_IO Interfacing.ppt
Microprocessor_IO Interfacing.pptMicroprocessor_IO Interfacing.ppt
Microprocessor_IO Interfacing.ppt
Pratheep Ganesan
 

Similar to Io pro (20)

COA-Unit5-ppt2.pptx
COA-Unit5-ppt2.pptxCOA-Unit5-ppt2.pptx
COA-Unit5-ppt2.pptx
 
Computer organization
Computer organizationComputer organization
Computer organization
 
IO hardware
IO hardwareIO hardware
IO hardware
 
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptxUNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
UNIT 5- UNDERSTANDING THE SYSTEM DESIGN PROCESS.pptx
 
IO organization.ppt
IO organization.pptIO organization.ppt
IO organization.ppt
 
unit-5 ppt.ppt
unit-5 ppt.pptunit-5 ppt.ppt
unit-5 ppt.ppt
 
Mca admission in india
Mca admission in indiaMca admission in india
Mca admission in india
 
420214730-15cs34-module-2-pptx.pptx
420214730-15cs34-module-2-pptx.pptx420214730-15cs34-module-2-pptx.pptx
420214730-15cs34-module-2-pptx.pptx
 
UNIT 2.pptx
UNIT 2.pptxUNIT 2.pptx
UNIT 2.pptx
 
chapter7-io organization.pptx
chapter7-io organization.pptxchapter7-io organization.pptx
chapter7-io organization.pptx
 
Operating system- Chapter 1.pptx to study
Operating system- Chapter 1.pptx to studyOperating system- Chapter 1.pptx to study
Operating system- Chapter 1.pptx to study
 
I/O System
I/O SystemI/O System
I/O System
 
Chapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptxChapter7_InputOutputStorageSystems.pptx
Chapter7_InputOutputStorageSystems.pptx
 
8555046.ppt
8555046.ppt8555046.ppt
8555046.ppt
 
Top schools in delhi ncr
Top schools in delhi ncrTop schools in delhi ncr
Top schools in delhi ncr
 
CO--MODULE-1 (b) - Input-Output-Organization.pptx
CO--MODULE-1 (b) - Input-Output-Organization.pptxCO--MODULE-1 (b) - Input-Output-Organization.pptx
CO--MODULE-1 (b) - Input-Output-Organization.pptx
 
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
 
Iosystemspre final-160922112930
Iosystemspre final-160922112930Iosystemspre final-160922112930
Iosystemspre final-160922112930
 
Bca examination 2015 csa
Bca examination 2015 csaBca examination 2015 csa
Bca examination 2015 csa
 
Microprocessor_IO Interfacing.ppt
Microprocessor_IO Interfacing.pptMicroprocessor_IO Interfacing.ppt
Microprocessor_IO Interfacing.ppt
 

More from cs19club

Podd notes
Podd notesPodd notes
Podd notes
cs19club
 
Podd note 1
Podd note 1Podd note 1
Podd note 1
cs19club
 
Podd mod6
Podd mod6Podd mod6
Podd mod6
cs19club
 
Module 3
Module 3Module 3
Module 3
cs19club
 
Ch05
Ch05Ch05
Ch05
cs19club
 
Ch04
Ch04Ch04
Ch04
cs19club
 
Oodp extra2
Oodp extra2Oodp extra2
Oodp extra2
cs19club
 
Oodp mod4
Oodp mod4Oodp mod4
Oodp mod4
cs19club
 
Module vi
Module viModule vi
Module vi
cs19club
 
Module5 part2
Module5 part2Module5 part2
Module5 part2
cs19club
 
Floating point arithmetic operations (1)
Floating point arithmetic operations (1)Floating point arithmetic operations (1)
Floating point arithmetic operations (1)
cs19club
 
Addition and subtraction with signed magnitude data (mano
Addition and subtraction with signed magnitude data (manoAddition and subtraction with signed magnitude data (mano
Addition and subtraction with signed magnitude data (mano
cs19club
 
Coa module1
Coa module1Coa module1
Coa module1
cs19club
 

More from cs19club (13)

Podd notes
Podd notesPodd notes
Podd notes
 
Podd note 1
Podd note 1Podd note 1
Podd note 1
 
Podd mod6
Podd mod6Podd mod6
Podd mod6
 
Module 3
Module 3Module 3
Module 3
 
Ch05
Ch05Ch05
Ch05
 
Ch04
Ch04Ch04
Ch04
 
Oodp extra2
Oodp extra2Oodp extra2
Oodp extra2
 
Oodp mod4
Oodp mod4Oodp mod4
Oodp mod4
 
Module vi
Module viModule vi
Module vi
 
Module5 part2
Module5 part2Module5 part2
Module5 part2
 
Floating point arithmetic operations (1)
Floating point arithmetic operations (1)Floating point arithmetic operations (1)
Floating point arithmetic operations (1)
 
Addition and subtraction with signed magnitude data (mano
Addition and subtraction with signed magnitude data (manoAddition and subtraction with signed magnitude data (mano
Addition and subtraction with signed magnitude data (mano
 
Coa module1
Coa module1Coa module1
Coa module1
 

Recently uploaded

MARUTI SUZUKI- A Successful Joint Venture in India.pptx
MARUTI SUZUKI- A Successful Joint Venture in India.pptxMARUTI SUZUKI- A Successful Joint Venture in India.pptx
MARUTI SUZUKI- A Successful Joint Venture in India.pptx
bennyroshan06
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
EverAndrsGuerraGuerr
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
Anna Sz.
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
Tamralipta Mahavidyalaya
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
Jisc
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
EugeneSaldivar
 
special B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdfspecial B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdf
Special education needs
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
DeeptiGupta154
 
How to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERPHow to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERP
Celine George
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
siemaillard
 
PART A. Introduction to Costumer Service
PART A. Introduction to Costumer ServicePART A. Introduction to Costumer Service
PART A. Introduction to Costumer Service
PedroFerreira53928
 
Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
Thiyagu K
 
Cambridge International AS A Level Biology Coursebook - EBook (MaryFosbery J...
Cambridge International AS  A Level Biology Coursebook - EBook (MaryFosbery J...Cambridge International AS  A Level Biology Coursebook - EBook (MaryFosbery J...
Cambridge International AS A Level Biology Coursebook - EBook (MaryFosbery J...
AzmatAli747758
 
How to Split Bills in the Odoo 17 POS Module
How to Split Bills in the Odoo 17 POS ModuleHow to Split Bills in the Odoo 17 POS Module
How to Split Bills in the Odoo 17 POS Module
Celine George
 
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
Nguyen Thanh Tu Collection
 
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptxStudents, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
EduSkills OECD
 
Template Jadual Bertugas Kelas (Boleh Edit)
Template Jadual Bertugas Kelas (Boleh Edit)Template Jadual Bertugas Kelas (Boleh Edit)
Template Jadual Bertugas Kelas (Boleh Edit)
rosedainty
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
JosvitaDsouza2
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Thiyagu K
 
How to Break the cycle of negative Thoughts
How to Break the cycle of negative ThoughtsHow to Break the cycle of negative Thoughts
How to Break the cycle of negative Thoughts
Col Mukteshwar Prasad
 

Recently uploaded (20)

MARUTI SUZUKI- A Successful Joint Venture in India.pptx
MARUTI SUZUKI- A Successful Joint Venture in India.pptxMARUTI SUZUKI- A Successful Joint Venture in India.pptx
MARUTI SUZUKI- A Successful Joint Venture in India.pptx
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
 
special B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdfspecial B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdf
 
Overview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with MechanismOverview on Edible Vaccine: Pros & Cons with Mechanism
Overview on Edible Vaccine: Pros & Cons with Mechanism
 
How to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERPHow to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERP
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 
PART A. Introduction to Costumer Service
PART A. Introduction to Costumer ServicePART A. Introduction to Costumer Service
PART A. Introduction to Costumer Service
 
Unit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdfUnit 8 - Information and Communication Technology (Paper I).pdf
Unit 8 - Information and Communication Technology (Paper I).pdf
 
Cambridge International AS A Level Biology Coursebook - EBook (MaryFosbery J...
Cambridge International AS  A Level Biology Coursebook - EBook (MaryFosbery J...Cambridge International AS  A Level Biology Coursebook - EBook (MaryFosbery J...
Cambridge International AS A Level Biology Coursebook - EBook (MaryFosbery J...
 
How to Split Bills in the Odoo 17 POS Module
How to Split Bills in the Odoo 17 POS ModuleHow to Split Bills in the Odoo 17 POS Module
How to Split Bills in the Odoo 17 POS Module
 
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
 
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptxStudents, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
 
Template Jadual Bertugas Kelas (Boleh Edit)
Template Jadual Bertugas Kelas (Boleh Edit)Template Jadual Bertugas Kelas (Boleh Edit)
Template Jadual Bertugas Kelas (Boleh Edit)
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
 
How to Break the cycle of negative Thoughts
How to Break the cycle of negative ThoughtsHow to Break the cycle of negative Thoughts
How to Break the cycle of negative Thoughts
 

Io pro

  • 1. Jin-Fu Li Department of Electrical Engineering National Central University Jungli, Taiwan Chapter 5Chapter 5 Input/Output OrganizationInput/Output Organization
  • 2. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 2 Accessing I/O Devices Interrupts Direct Memory Access Buses Interface Circuits Standard I/O Interfaces Outline
  • 3. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 3 Content Coverage Main Memory System Input/Output System Arithmetic and Logic Unit Operational Registers Program Counter Control Unit Data/InstructionAddress Central Processing Unit (CPU) Cache memory Instruction Sets
  • 4. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 4 Accessing I/O Devices Single-bus structure The bus enables all the devices connected to it to exchange information Typically, the bus consists of three sets of lines used to carry address, data, and control signals Each I/O device is assigned a unique set of addresses Processor Memory I/O device 1 I/O device n Bus
  • 5. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 5 I/O Mapping Memory mapped I/O Devices and memory share an address space I/O looks just like memory read/write No special commands for I/O Large selection of memory access commands available Isolated I/O Separate address spaces Need I/O or memory select lines Special commands for I/O Limited set
  • 6. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 6 Memory-Mapped I/O When I/O devices and the memory share the same address space, the arrangement is called memory- mapped I/O With memory-mapped I/O, any machine instruction that can access memory can be used to transfer data to or from an I/O device Most computer systems use memory-mapped I/O. Some processors have special IN and OUT instructions to perform I/O transfers When building a computer system based on these processors, the designer has the option of connecting I/O devices to use the special I/O address space or simply incorporating them as part of the memory address space
  • 7. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 7 I/O Interface for an Input Device The address decoder, the data and status registers, and the control circuitry required to coordinate I/O transfers constitute the device’s interface circuit Control circuits Address decoder Data and status registers Bus Data lines Control lines Input device Address lines
  • 8. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 8 I/O Techniques Programmed Interrupt driven Direct Memory Access (DMA)
  • 9. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 9 Program-Controlled I/O Consider a simple example of I/O operations involving a keyboard and a display device in a computer system. The four registers shown below are used in the data transfer operations The two flags KIRQ and DIRQ in STATUS register are used in conjunction with interrupts DATAIN DATAOUT STATUS SINSOUTKIRQDIRQ CONTROL KENDEN 7 6 5 4 3 2 1 0
  • 10. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 10 An Example Move #LINE, R0 Initialize memory pointer WAITK TestBit #0,STATUS Test SIN Branch=0 WAITK Wait for character to be entered Move DATAIN,R1 Read character WAITD TestBit #1,STATUS Test SOUT Branch=0 WAITD Wait for display to become ready Move R1,DATAOUT Send character to display Move R1,(R0)+ Store character and advance pointer Compare #$0D,R1 Check if Carriage Return Branch=0 WAITK If not, get another character Move #$0A,DATAOUT Otherwise, send Line Feed Call PROCESS Call a subroutine to process the input line A program that reads one line from the keyboard, stores it in memory buffer, and echoes it back to the display
  • 11. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 11 Program-Controlled I/O The example described above illustrates program- controlled I/O, in which the processor repeatedly checks a status flag to achieve the required synchronization between the processor and an input or output device. We say that the processor polls the devices There are two other commonly used mechanisms for implementing I/O operations: interrupts and direct memory access Interrupts: synchronization is achieved by having the I/O device send a special signal over the bus whenever it is ready for a data transfer operation Direct memory access: it involves having the device interface transfer data directly to or from the memory
  • 12. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 12 Interrupts To avoid the processor being not performing any useful computation, a hardware signal called an interrupt to the processor can do it. At least one of the bus control lines, called an interrupt-request line, is usually dedicated for this purpose An interrupt-service routine usually is needed and is executed when an interrupt request is issued On the other hand, the processor must inform the device that its request has been recognized so that it may remove its interrupt-request signal. An interrupt-acknowledge signal serves this function
  • 13. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 13 Example Program 1 COMPUTE routine Program 2 PRINT routine Interrupt occurs here 1 2 i i+1 M
  • 14. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 14 Interrupt-Service Routine & Subroutine Treatment of an interrupt-service routine is very similar to that of a subroutine An important departure from the similarity should be noted A subroutine performs a function required by the program from which it is called. The interrupt-service routine may not have anything in common with the program being executed at the time the interrupt request is received. In fact, the two programs often belong to different users Before executing the interrupt-service routine, any information that may be altered during the execution of that routine must be saved. This information must be restored before the interrupted program is resumed
  • 15. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 15 Interrupt Latency The information that needs to be saved and restored typically includes the condition code flags and the contents of any registers used by both the interrupted program and the interrupt-service routine Saving registers also increases the delay between the time an interrupt request is received and the start of execution of the interrupt-service routine. The delay is called interrupt latency Typically, the processor saves only the contents of the program counter and the processor status register. Any additional information that needs to be saved must be saved by program instruction at the beginning of the interrupt-service routine and restored at the end of the routine
  • 16. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 16 Interrupt Hardware An equivalent circuit for an open-drain bus used to implement a common interrupt-request line INTR INTR1 INTR2 INTRn Processor INTR R Vdd INTR=INTR1+INTR2+…+INTRn
  • 17. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 17 Handling Multiple Devices Handling multiple devices gives rise to a number of questions: How can the processor recognize the device requesting an interrupt? Given that different devices are likely to require different interrupt-service routines, how can the processor obtain the starting address of the appropriate routine in each case? Should a device be allowed to interrupt the processor while another interrupt is being serviced? How should two or more simultaneous interrupt request be handled? The information needed to determine whether a device is requesting an interrupt is available in its status register When a device raises an interrupt request, it sets to 1 one of the bits in its status register, which we will call the IRQ bit
  • 18. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 18 Identify the Interrupting Device The simplest way to identify the interrupting device is to have the interrupt-service routine poll all the I/O devices connected to the bus The polling scheme is easy to implement. Its main disadvantage is the time spent interrogating all the devices A device requesting an interrupt may identify itself directly to the processor. Then, the processor can immediately start executing the corresponding interrupt-service routine. This is called vectored interrupts An interrupt request from a high-priority device should be accepted while the processor is servicing another request from a lower-priority device
  • 19. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 19 Interrupt Priority The processor’s priority is usually encoded in a few bits of the processor status word. It can be changed by program instructions that write into the program status register (PS). These are privileged instructions, which can be executed only while the processor is running in the supervisor mode The processor is in the supervisor mode only when executing operating system routines. It switches to the user mode before beginning to execute application program An attempt to execute a privileged instruction while in the user mode leads to a special type of interrupt called a privilege exception
  • 20. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 20 Implementation of Interrupt Priority An example of the implementation of a multiple- priority schemeProcessor Device 1 Device 2 Device p INTA1 INTR1 Priority arbitration circuit INTRp INTAp
  • 21. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 21 Simultaneous Requests Consider the problem of simultaneous arrivals of interrupt requests from two or more devices. The processor must have some means of deciding which request to service first Interrupt priority scheme with daisy chain Device 1 Device 2 Device n INTA INTR Processor
  • 22. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 22 Priority Group Combination of the interrupt priority scheme with daisy chain and with individual interrupt- request and interrupt-acknowledge lines Processor Priority arbitration circuit Device Device Device INTA1 INTR1 Device Device Device INTAp INTRp
  • 23. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 23 Direct Memory Access To transfer large blocks of data at high speed, a special control unit may be provided between an external device and the main memory, without continuous intervention by the processor. This approach is called direct memory access (DMA) DMA transfers are performed by a control circuit that is part of the I/O device interface. We refer to this circuit as a DMA controller. Since it has to transfer blocks of data, the DMA controller must increment the memory address for successive words and keep track of the number of transfers
  • 24. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 24 DMA Controller Although a DMA controller can transfer data without intervention by the processor, its operation must be under the control of a program executed by the processor An example 31 30 1 0 IRQ IE Status and control Starting address Word count Done R/W
  • 25. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 25 DMA Controller in a Computer System Processor Main memory Disk/DMA controller System bus DMA controller Printer Keyboard Disk Disk Network Interface
  • 26. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 26 Memory Access Priority Memory accesses by the processor and the DMA controllers are interwoven. Request by DMA devices for using the bus are always given higher priority than processor requests. Among different DMA devices, top priority is given to high-speed peripherals such as a disk, a high- speed network interface, etc. Since the processor originates most memory access cycles, the DMA controller can be said to “steal” memory cycles from the processor. Hence, this interweaving technique is usually called cycle stealing The DMA controller may transfer a block of data without interruption. This is called block/burst mode
  • 27. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 27 Bus Arbitration A conflict may arise if both the processor and a DMA controller or two DMA controllers try to use the bus at the same time to access the main memory. To resolve this problem, an arbitration procedure on bus is needed The device that is allowed to initiate data transfer on the bus at any given time is called the bus master. When the current master relinquishes control of the bus, another device can acquire this status Bus arbitration is the process by which the next device to become the bus master take into account the needs of various devices by establishing a priority system for gaining access to the bus
  • 28. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 28 Bus Arbitration There are two approaches to bus arbitration Centralized and distributed In centralized arbitration, a single bus arbiter performs the required arbitration In distributed arbitration, all devices participate in the selection of the next bus master
  • 29. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 29 Centralized Arbitration DMA Controller 1BG1 BBSY Processor DMA Controller 2 BR BG2 BG1 BG2 BBSY BR Processor DMA controller 2 Processor
  • 30. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 30 Distributed Arbitration ARB3 ARB2 ARB1 ARB0 Start-Arbitration Vcc O.C. Interface circuit for device A 0 1 0 1 0 1 1 1 Assume that IDs of A and B are 5 and 6. Also, the code seen by both devices is 0111
  • 31. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 31 Buses A bus protocol is the set of rules that govern the behavior of various devices connected to the bus as to when to place information on the bus, assert control signals, and so on In a synchronous bus, all devices derive timing information from a common clock line. Equal spaced pulses on this line define equal time intervals In the simplest form of a synchronous bus, each of these intervals constitutes a bus cycle during which one data transfer can take place
  • 32. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 32 A Synchronous Bus Example t2t1 t0 Bus clock Address and command Data Bus Cycle Timing of an input transfer on a synchronous bus
  • 33. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 33 A Synchronous Bus Example Detail timing diagram t2t1 tAM Bus clock Address and command Data t1 tAS tDM tDS Data Address and command Seen by slave Seen by master Slave send the requested data
  • 34. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 34 Input Transfer Using Multiple Clock Cycles Address Command Clock Data Slave-ready 1 2 3 4
  • 35. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 35 Asynchronous Bus An alternative scheme for controlling data transfers on the bus is based on the use of a handshake between the master and slave Address and command Master-ready Data Slave-ready Bus cycle t0 t1 t2 t3 t4 t5
  • 36. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 36 Asynchronous Bus Handshake control of data transfer during an output operation Address and command Master-ready Data Slave-ready Bus cycle t0 t1 t2 t3 t4 t5
  • 37. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 37 Discussion The choice of a particular design involves trade-offs among factors such as Simplicity of the device interface Ability to accommodate device interfaces that introduce different amounts of delay Total time required for bus transfer Ability to detect errors results from addressing a nonexistent device or from an interface malfunction Asynchronous bus The handshake process eliminates the need for synchronization of the sender and receiver clock, thus simplifying timing design Synchronous bus Clock circuitry must be designed carefully to ensure proper synchronization, and delays must be kept within strict bounds
  • 38. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 38 Interface Circuits Keyboard to processor connection When a key is pressed, the Valid signal changes from 0 o 1, causing the ASCII code to be loaded into DATAIN and SIN to be set to 1 The status flag SIN is cleared to 0 when the processor reads the contents of the DATAIN register Processor Encoder and Debouncing circuit DATAIN SIN Input Interface Keyboard switches Valid Data Data Address Master-ready Slave-ready R/W
  • 39. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 39 Input Interface Circuit Address decoder Status flag Q7 D7 Q0 D0 Slave- ready D7 D0 SIN Keyboard data Valid A31 A1 A0 Read- data Read- status 1 Master- ready DATAIN R/W
  • 40. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 40 Circuit for the Status Flag Block Q D Q SIN Read-data Master-ready 1 Valid Clear
  • 41. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 41 Printer to Processor Connection The interface contains a data register, DATAOUT, and a status flag, SOUT The SOUT flag is set to 1 when the printer is ready to accept another character, and it is cleared to 0 when a new character is loaded into DATAOUT by the processor When the printer is ready to accept a character, it asserts its idle signal Processor DATAOUT SOUT Output Interface Data Address Master-ready Slave-ready R/W Printer Idle Data Valid
  • 42. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 42 Output Interface Circuit Address decoder Handshake control D7 Q7 D0 Q0 Slave- ready D7 D0 SOUT Printer data Idle A31 A1 A0 Load- data Read- status 1 Master- ready DATAOUT R/W D1 D1 Q1 Valid
  • 43. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 43 A General 8-Bit Parallel Interface DATAIN DATAOUT Data Direction Register D7 D0 P7 P0
  • 44. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 44 Output Interface Circuit for a Bus Protocol Address decoder Handshake control D7 Q7 D0 Q0 D7 D0 SOUT Printer data Idle A31 A1 A0 Load- data Read- status R/W D1 D1 Q1 Valid Clock My- address Timing Logic Go Respond Go=1 Idle My-address DATAOUT Slave- ready
  • 45. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 45 Timing Diagram for an Output Operation Clock Address Data Go Slave-ready R/W 1 2 3 Time
  • 46. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 46 Serial Port A serial port is used to connect the processor to I/O devices that require transmission of data one bit at a time The key feature of an interface circuit for a serial port is that it is capable of communicating in a bit-serial fashion on the device side and in a bit- parallel fashion on the bus side The transformation between the parallel and serial formats is achieved with shift registers that have parallel access capability
  • 47. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 47 A Serial Interface Input shift register DATAIN DATAOUT Output shift register Serial input Serial output D7 D0
  • 48. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 48 Standard I/O Interfaces The processor bus is the bus defined by the signals on the processor chip itself. Devices that require a very high speed connection to the processor, such as the main memory, may be connected directly to this bus The motherboard usually provides another bus that can support more devices. The two buses are interconnected by a circuit, which we called a bridge, that translates the signals and protocols of one bus into those of the other It is impossible to define a uniform standards for the processor bus. The structure of this bus is closely tied to the architecture of the processor The expansion bus is not subject to these limitations, and therefore it can use a standardized signaling structure
  • 49. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 49 Peripheral Component Interconnect Bus Use of a PCI bus in a computer system Host Main memory Disk PCI Bus Printer Ethernet interface PCI bridge
  • 50. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 50 PCI Bus The bus support three independent address spaces: memory, I/O, and configuration. The I/O address space is intended for use with processors, such Pentium, that have a separate I/O address space. However, the system designer may choose to use memory-mapped I/O even when a separate I/O address space is available The configuration space is intended to give the PCI its plug-and-play capability. A 4-bit command that accompanies the address identifies which of the three spaces is being used in a given data transfer operation
  • 51. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 51 Data Transfer Signals on the PCI Bus Name CLK FRAME# AD C/BE# IRDY#, TRDY# DEVSEL# IDSEL# A 33-MHz or 66MHz clock Sent by the initiator to indicate the duration of a transaction 32 address/data lines, which may be optionally increased to 64 4 command/byte-enable lines (8 for 64-bit bus) Initiator-ready and Target-ready signals A response from the device indicating that it has recognized its Address and is ready for a data transfer transaction Initialization Device Select Function
  • 52. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 52 A Read Operation on the PCI Bus CLK 1 2 3 4 5 6 7 Frame# AD Address #1 #2 #3 #4 C/BE# IRDY# TRDY# DEVSEL# Cmnd Byte enable
  • 53. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 53 Universal Serial Bus (USB) The USB has been designed to meet several key objectives Provide a simple, low-cost, and easy to use interconnection system that overcomes the difficulties due to the limited number of I/O ports available on a computer Accommodate a wide range of data transfer characteristics for I/O devices, including telephone and Internet connections Enhance user convenience through a “plug-and-play” mode of operation
  • 54. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 54 USB Structure A serial transmission format has been chosen for the USB because a serial bus satisfies the low-cost and flexibility requirements Clock and data information are encoded together and transmitted as a single signal Hence, there are no limitations on clock frequency or distance arising from data skew To accommodate a large number of devices that can be added or removed at any time, the USB has the tree structure Each node of the tree has a device called a hub, which acts as an intermediate control point between the host and the I/O device At the root of the tree, a root hub connects the entire tree to the host computer
  • 55. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 55 USB Tree Structure Root hub Host Computer Hub Hub Hub I/O device I/O device I/O device I/O device I/O device I/O device
  • 56. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 56 USB Tree Structure The tree structure enables many devices to be connected while using only simple point-to-point serial links Each hub has a number of ports where devices may be connected, including other hubs In normal operation, a hub copies a message that it receives from its upstream connection to all its downstream ports As a result, a message sent by the host computer is broadcast to all I/O devices, but only the addressed device will respond to that message A message sent from an I/O device is sent only upstream towards the root of the tree and is not seen by other devices Hence, USB enables the host to communicate with the I/O devices, but it does not enable these devices to communicate with each other
  • 57. Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 57 USB Protocols All information transferred over the USB is organized in packets, where a packet consists of one or more bytes of information The information transferred on the USB can be divided into two broad categories: control and data Control packets perform such tasks as addressing a device to initiate data transfer, acknowledging that data have been received correctly, or indicating an error Data packets carry information that is delivered to a device. For example, input and output data are transferred inside data packets