English
Language : 

Z80185 Datasheet, PDF (91/95 Pages) Zilog, Inc. – SMART PERIPHERAL CONTROLLERS
Zilog
PRELIMINARY
Z80185 PIA AND MISCELLANEOUS REGISTERS (Continued)
Parallel Ports
Z80185/Z80195
SMART PERIPHERAL CONTROLLES
The Z80185 has two 8-bit bidirectional ports. Each bit is
individually programmable for input or output. Each port
includes two registers: the Port Direction Control Register
and the Port Data Register. The second port also includes
an Alternate Address that is used with the Bidirectional
Centronics feature.
The data direction register determines which of the PIA27-
20 pins are inputs and outputs. When a bit is set to a 1, the
corresponding pin is an input. If the bit is 0, then the
corresponding bit is an output. These settings can be
overridden by the Bidirectional Centronics Controller.
7 65 4 321 0
1 11 1 1 11 1
PIA 1 Data Direction Register
0 = Output
1 = Input
Figure 94. PIA 1 Data Direction Register
(I/O Address %E0)
The data direction register determines which of the PIA16-
10 pins are inputs and outputs. When a bit is set to 1, the
corresponding bit in the PIA 1 Data Register is an input. If
the bit is 0, then the corresponding pin is an output. These
bits must be set appropriately if these pins are used for
CTC inputs and outputs.
765 43210
0 00 0 0 00 0
PIA 1 Data Register
Figure 95. PIA 1 Data Register (I/O Address %E1)
When the processor writes to the PIA 1 Data Register, the
data is stored in the internal buffer. Any bits that are output
are then driven on to the pins.
When the processor reads the PIA 1 Data Register, the
data on the external pins is returned.
7 65 4 321 0
0 00 0 0 00 0
PIA 2 Data Register
Figure 97. PIA 2 Data Register (I/O Address %E3)
When the processor writes to the PIA 2 Data Register, the
data is stored in the internal buffer. Any bits that are output
are then driven on to the pins. In certain modes of the
Bidirectional Centronics Controller, an intermediate regis-
ter called the Output Holding Register is activated, and the
transfer of data from the OHR to the pins is under the
control of the controller.
When the processor reads the PIA 2 Data Register, the
data on the external pins is returned. In certain modes of
the Bidirectional Centronics Controller, reading from this
address reads the data stored in the port register from
PIA27-20 under the control of the controller.
7 65 4 321 0
0 00 0 0 00 0
PIA 2 Data Register
Figure 98. PIA 2 Data Alternate Address
(RW) (I/O Address %EE)
765 43210
0 00 0 0 00 0
PIA 2 Data Register
Figure 96. PIA 2 Data Direction Register
(I/O Address %E2)
Reading and writing this register is exactly the same as
reading and writing address E3 as described above,
except that in certain modes of the Bidirectional Centronics
Controller, writing to this address sets a “ninth bit” in the
opposite sense from writing address E3, and this drives
one of the control outputs with the opposite polarity.
DS971850301
91