S1C88348/317/316/308 TECHNICAL HARDWARE
EPSON
I-71
5 PERIPHERAL CIRCUITS AND THEIR OPERATION (I/O Ports)
5.7 I/O Ports (P ports)
5.7.1 Configuration of I/O ports
The S1C883xx is equipped with 16 bits of I/O ports
(P00–P07, P10–P17). The configuration of these I/O
ports will vary according to the bus mode as shown
below.
Table 5.7.1.1 Configuration of I/O ports
With respect to the data bus, see "5.2 System
Controller and Bus Control".
Figure 5.7.1.1 shows the structure of an I/O port.
Input
control
VDD
VSS
Data
bus
Pxx
Data
register
I/O control
register
Mask
option
*1
*2
*1: During output mode
*2: During input mode
Fig. 5.7.1.1 Structure of I/O port
I/O port can be set for input or output mode in one
bit unit. These settings are performed by writing
data to the I/O control registers.
I/O port terminals P10–P13 and P14–P17 are shared
with serial interface input/output terminal and
analog comparator input terminals, respectively.
The function of each terminals is switchable in
software. With respect to serial interface and analog
comparator, see "5.8 Serial Interface" and "5.14
Analog Comparator", respectively.
The data registers and I/O control registers of I/O
ports set for data bus and serial interface output
terminals use are usable as general purpose
registers with read/write capabilities which do not
affect I/O activities of the terminal.
The same as above, the I/O control register of I/O
port set for serial interface input terminal use is
usable as general purpose register.
5.7.2 Mask option
I/O port pull-up resistors
P00 ............ s
s With resistor
s
s Gate direct
P01 ............ s
s With resistor
s
s Gate direct
P02 ............ s
s With resistor
s
s Gate direct
P03 ............ s
s With resistor
s
s Gate direct
P04 ............ s
s With resistor
s
s Gate direct
P05 ............ s
s With resistor
s
s Gate direct
P06 ............ s
s With resistor
s
s Gate direct
P07 ............ s
s With resistor
s
s Gate direct
P10 ............ s
s With resistor
s
s Gate direct
P11 ............ s
s With resistor
s
s Gate direct
P12 ............ s
s With resistor
s
s Gate direct
P13 ............ s
s With resistor
s
s Gate direct
P14 ............ s
s With resistor
s
s Gate direct
P15 ............ s
s With resistor
s
s Gate direct
P16 ............ s
s With resistor
s
s Gate direct
P17 ............ s
s With resistor
s
s Gate direct
I/O ports P00–P07 and P10–P17 are equipped with
a pull-up resistor which goes ON in the input
mode. Whether this resistor is used or not can be
selected for each port (one bit unit).
In cases where the 'With resistor' option is selected,
the pull-up resistor goes ON when the port is in
input mode.
When changing the port terminal from LOW level
to HIGH with the built-in pull-up resistor, a delay
in the waveform rise time will occur depending on
the time constant of the pull-up resistor and the
load capacitance of the terminal. It is necessary to
set an appropriate wait time for introduction of an
I/O port. Make this wait time the amount of time
or more calculated by the following expression.
Wait time = RIN x (CIN + load capacitance on the
board) x 1.6 [sec]
RIN: Pull up resistance Max. value
CIN: Terminal capacitance Max. value
When the analog comparator is used, select "Gate
direct" for I/O ports (P14–P15 or P16–P17, or both)
which then become input terminals.
For unused I/O ports, select the default setting of
"With resistor".
Terminal
P00
P01
P02
P03
P04
P05
P06
P07
P10
P11
P12
P13
P14
P15
P16
P17
I/O port P00
I/O port P01
I/O port P02
I/O port P03
I/O port P04
I/O port P05
I/O port P06
I/O port P07
Bus mode
Expanded 64K Expanded 512K
Single chip
Data bus D0
Data bus D1
Data bus D2
Data bus D3
Data bus D4
Data bus D5
Data bus D6
Data bus D7
I/O port P10 (SIN)
I/O port P11 (SOUT)
I/O port P12 (SCLK)
I/O port P13 (SRDY)
I/O port P14 (CMPP0)
I/O port P15 (CMPM0)
I/O port P16 (CMPP1)
I/O port P17 (CMPM1)