Input/Output Ports - Toshiba TC9314F Manual

Cmos digital integrated circuit silicon monolithic
Table of Contents

Advertisement

Input/Output Ports

1. I/O Ports − − − − 1, − − − − 2, − − − − 3, − − − − 4, − − − − 5, − − − − 6, and − − − − 7
I/O ports −1, −2, −3, −4, −5, −6, and −7 are 4 bit ports. Each bit can be set to either input or output by the
I/O control internal ports. To set a port to input, set the corresponding bit in the I/O control port to "0". To
set the port to output, set the corresponding bit in the I/O control port to "1".
When set to input, executing the IN3 instruction for the corresponding I/O port reads the current I/O
port data to data memory. At this time, the contents of the output side latch are not affected by the input
data.
When set to output, executing the OUT3 instruction for the corresponding I/O port controls the output
state of the port. Executing the IN3 instruction reads the current output port data to data memory.
I/O port 3 is also used for the 6 bit A/D, D/A converter analog inputs and output. I/O port 4 is also used
for serial interface. When using I/O ports 3 and 4, set the DA/AD control port and SIO ON bit to "0". I/O
ports 5~7 are also used for LCD driver output. To use one of these pins as an I/O port, set the SEG I/O bit
corresponding to the pin to "0".
After a system reset, the ports that are also used by the serial interface and A/D, D/A converter are set as
I/O ports. Also, after a system reset, the I/O ports are set as input ports, and the pins that are used by both
the LCD driver and I/O ports are set to LCD driver output. (see the respective sections on the serial
interface, the A/D, D/A converter, and the LCD driver.)
A change in the input state of an I/O port 1 port pin set as an input port releases the execution of a WAIT
or CKSTP instruction and restarts the CPU. Similarly, when the I/O bit of the MUTE port is set to "1", a
change in the input state forcibly sets the MUTE bit of the MUTE port to "1".
Note 58: When the pins shared by the LCD driver and I/O ports are set as LCD driver pins, the I/O port
input/output setting and the I/O port data are "Don't care".
Note 59: After a system reset, all the bits of the I/O control ports are reset to "0". This sets all I/O ports as input
ports.
Note 60: During clock stop mode, all I/O ports set as output ports automatically go to the low level. However, the
output latches retain their existing data.
54
TC9314F
2003-07-03

Advertisement

Table of Contents
loading

Table of Contents