Chapter 3 Port Functions

3-2-2 I/O Port Control Registers

This section describes the special function registers that control the MN101C117's I/O ports.

Data Registers

• PnOUT registers

Data registers to output to the ports.

Data written to these registers is output from the ports.

0Low (Vss level) is output.

1High (Vdd level) is output.

PnIN registers

Data registers to input data from the ports.

The value of data at the pins can be input by reading these registers.

These are read-only registers.

0Pin is low.

1Pin is high.

Input and output registers are mapped to separate addresses.

To use these ports for I/O, configure them as I/O ports in the PnOMD/PnIMD registers, described in this section.

Direction Control Registers

• PnDIR registers

0Input mode

1Output mode

These registers set the port for use as an input or output.

Pull-up/Pull-down Resistor Control Registers

• PnPLU registers

These register settings determine whether internal pull-up resistors are added to the ports.

0No pull-up / pull-down resistor

1Pull-up / Pull down resistor

PnPLUD registers

These register settings determine whether internal pull-up or pull-down resistors are added to the ports.

0No pull-up / pull-down resistor

1Pull-up / Pull down resistor

Port Control Registers

45

Page 59
Image 59
Panasonic MN101C00 user manual 2 I/O Port Control Registers