PERIPHERAL DEVICE
I/Odevices attached to the computer
are called peripheral devices.
Most common peripherals are key
board, display and printer.
Other peripherals are magnetic disks,
pen drives.
I/O INTERFACES
It provides a method for transferring
information between internal storage and
external I/O devices.
The difference between peripheral devices
and central computer.
Data transfer rate of peripheral devices are
slower than CPU.
Data codes and formats in peripherals
devices differ from word format in CPU and
memory.
Interfaces:
The word interface is the general term for the
point of contact between two parts of the system.
Two interfaces means to attach two or more
component or system , via the respective
interface points for data exchange between the
two main types of interfaces are
CPU interface- between system bus and I/O
interface.
I/O interface- between the devices and the system
bus.
The main function of input-output
interface circuits are
Data conversion
Synchronization
Device selection.
Data conversion refers to conversion
between digital and analog signals and
conversion between serial and parallel
data formats.
Synchronationrefers to matching of
operating speeds of CPU and others
peripherals.
Device Selection refers to selection of
I/O device by CPU in a queue manner.
I/O bus and interfaces
modules
I/O bus consists of data line , address line and control
line.
Each peripheral devices has associated with in it
interface.
Each interface decode the address and control
received from the I/O bus, Interrupts them from the
peripheral and provides signals for the peripherals
control also synchronise the data flow and supervisors
the transfer between peripheral and processor.
I/O COMMAND
The function code refers to as IO command with
the instruction that is executed in the interface and
its attached peripheral unit.
There are four of command , that interface may
receive.
Control command
Status command
Output data
Input data
Control command:
It is to activate the peripherals and to
inform it what to do.
Status command:
It is used to text the various status
condition in the peripheral and
interface.
Output data:
The interface to respond by transferring data
from the bus into one of its registers.
Input data:
In this case interface receive an item of data from
peripheral and places in registered.
I/O VERSUS MEMORY
BUS
In addition to communicating with I/O the
processor must communicate with memory unit.
There are three ways that computer bus can be
used to communicate with memory and I/O.
Use one common bus for memory and I/O but
have separate control line, but same Address line
and data.
Use one common bus for memory and I/O with
common control lines
Use two separate bus one for memory and other
for I/O.
In the last method the computer has independent
set of data , address and control bus, one for
accessing memory and the other for I/O.
This is done by I/O processor(IOP).
In addition to CPU the memory communicate with
CPU and IOP through memory bus.
I/O is also called as data channel.
The purpose of IOP is to provide and independent
pathway for the transfer of information between
external devices and internal memory.
ISOLATED VERSUS MEMORY MAPPED I/O
Many computers use one common bus to transfer
information between memory or I/O and the CPU.
The distinction between memory transfer and I/O
transfer is made through separate read and write
lines.
The CPU specifies whether the Address on address
on address line is for a memory word or for an
interface register by enabling one of two possible
read or write lines.
I/O read and write control line are enable during
an memory transfer.
Isolated I/O method for assigning address in a
common bus.
In isolated I/O configuration CPU has distinct
input and output instruction and the instructions
associated with the dress of an interface register.
When CPU fetches and decodes the operation code
an input or I/O instruction address associated with
the instruction into common address line.
Memory I/O have different data type or each data
lines.
Memory address value are hot affected by address
since each have it own address space.
It employ only one set of read and write signals
and not distinguish between memory and I/O
address .
This configuration referred as memory mapped
I/O.
There is no specific input or output instructions.
CPU can manipulate I/O data in interface registers
with same instruction for manipulate memory
word.
The advantage is it can loaded store instruction for
reading and writing.
Also used to input and output data from I/O
registers.
Example of I/O interface
The block diagram consist of two data registers
called port , control registers , status registes , bus
buffers , and timing and control circuits.
The chip select and register select determine the
address assigned to the interface.
The I/O read and I/O write determines input and
output.
The four registers directly communicate with I/O
devices attached to the interface.
The control is send to the control register
the status information is received from
status register.
The interface register communicates with
cpu through the directional bus.
The address bus select the interface unit
through the chip select and two register
select inputs