Iotuni 2
Iotuni 2
Unit No 2
INTRODUCTION
• Interfacing of the one or more peripheral devices for the purpose of
communication with various input and output devices connected to
it.
• The PPI has three programmable parallel I/O ports viz., Port A, Port B and
Port C each of 8 bit width in one package.
• The BSR word can also be used for enabling or disabling the interrupt
signals generated by Port c when 8255 is programmed for mode 1 or
mode 2 operation.
Control Word for I/O mode
Mode 0 : Basic Input/output
• This mode provides simple input and output operations for each of the
three ports. Data is simply written to or read from a specified port.
• Basic functional definition
• In mode 0:
• There are two 8-bit ports (A and B) and two 4-bit ports [C (lower)] and [C
(upper)].
• Any port can be an input port or an output port.
• Outputs are latched.
• Inputs are not latched.
• 16 different input/output configurations are possible in this mode.
Mode1: Strobed Input/Output
• It provides means for transferring I/O data to or from a specified port
in conjunction with strobes or hand-shaking signals.
• Port A and port B use the lines on port C for handshaking signals.
Basic functional definition
• In mode1:
• There are two groups (Group A and B).
• Each group contains one 8-bit data port and one 4-bit control data
port.
• The 8-bit data port can be either an input port or an output port.
Both inputs and outputs are latched.
• The 4-bit port is used for control as well as for status of the 8-bit data
port.
Mode2 : Strobed Bidirectional Bus
• This functional configuration provides a means for communicating
with a peripheral device or Structure on a single 8-bit bus for both
transmitting and receiving data. Handshaking signals are provided to
maintain a proper bus flow discipline.
• There is one 8-bit bidirectional bus port (port A) and a 5-bit control
port (port C).
• The 5-bit control port (port C) is used for control as well as for status
of the 8-bit bidirectional bus port (port A).