1. Bit Set-Reset (BSR) Mode 2. I/O Modes
Operation Modes
AU
: May-04, 07, 08, 17, 18, Dec.-04, 09, 11, 13, 17, 19
The
individual bits of Port C can be set or reset by sending out a single OUT
instruction to the control register. When Port C is used for control/status
operation, this feature can be used to set or reset individual bits.
Mode
0 : Simple input/output
In
this mode, Ports A and B are used as two simple 8-bit I/O ports and Port C as
two 4-bit ports. Each port (or half - port, in case of C) can be programmed to
function as simply an input port or an output port. The input/output features
in Mode 0 are as follows :
1.
Outputs are latched. 2. Inputs are buffered, not latched.
3.
Ports do not have handshake or interrupt capability.
Mode
1 : Input/Output with handshake
In
this mode, input or output data transfer is controlled by handshaking signals.
Handshaking signals are used to transfer data between devices whose data
transfer speeds are not same. For example, computer can send data to the
printer with large speed but printer can't accept data and print data with this
rate. So computer has to send data with the speed with which printer can
accept. This type of data transfer is achieved by using handshaking signals
alongwith data signals. Fig. 8.4.1 shows data transfer between computer and
printer using handshaking signals.

These
handshaking signals are used to tell computer whether printer is ready to
accept the data or not. If printer is ready to accept the data then after
sending data on data bus, computer uses another handshaking signal
to tell printer that valid data is available on the data bus.
The
8255 mode 1 which supports handshaking has following features.
1.
Two ports (A and B) function as 8-bit I/O ports. They can be configured either
as input or output ports.
2.
Each port uses three lines from Port C as handshake signals. The remaining two
lines of Port C can be used for simple 1/O functions.
3.
Input and output data are latched.
4.
Interrupt logic is supported.
Mode
2 : Bi-directional I/O data transfer
This
mode allows bi-directional data transfer (transmission and reception) over a
single 8-bit data bus using handshaking signals. This feature is available only
in Group A with Port A as the 8-bit bidirectional data bus; and PC3
- PC7 are used for handshaking purpose. In this mode, both inputs
and outputs are latched. Due to use of a single 8-bit data bus for
bi-directional data transfer, the data sent out by the CPU through Port A
appears on the bus connecting it to the peripheral, only when the peripheral
requests it. The remaining lines of Port C i.e. PC0 - PC2
can be used for simple I/O functions. The Port B can be programmed in mode 0 or
in mode 1. When Port B is programmed in mode 1, PC0 - PC2
lines of Port C are used as handshaking signals.
Review Questions
1. Explain in detail
about various operating modes of 8255 PPI.
AU : May-07, Marks 16,
Dec.-ll,13,17,19, May-18, Marks 8
2. Explain the mode 0
of 8255 in detail.
AU : Dec.-04, Marks 16
3. Explain the
functioning of 8255 programmable peripheral interface and its modes.
AU : May-17, Marks 16
Microprocessors and Microcontrollers: Unit IV: (a) Programmable Peripheral Interface (PPI) - 8255 : Tag: : rogrammable Peripheral Interface (PPI) - 8255 - Operation Modes