Chapter 3 Port Functions

3-1 Overview

A total of 39 pins on the MN101C117, including those shared with special function pins, are allocated for the 7 ports of P0 to P2, P6 to P8, and PA. Each I/O port is assigned according to the special function register area in memory. I/O ports are operated in byte or bit units in the same way as RAM.

For each I/O port, the PnOUT register (port n output register) that sets the output value is assigned to memory address X'3F1n', and the PnIN register (port n input register) from which the input value is monitored is assigned to memory address X'3F2n'.

This I/O control is valid even when special functions are selected for the dual function pins.

Table 3-1-1 Status When Port Is Reset (single-chip mode)

Port

I/O Mode

Pull-up/Pull-down Resistor

I/O Port or Special Function

 

 

 

 

Port 0

Input mode

No pull-up resistor

I/O port

 

 

 

 

Port 1

Input mode

No pull-up resistor

I/O port

 

 

 

 

Port 2

Input mode

No pull-up resistor

I/O port

 

 

 

 

Port 6

Input mode

No pull-up resistor

I/O port

 

 

 

 

Port 7

Input mode

No pull-up/pull-down resistors

I/O port

 

 

 

 

Port 8

Input mode

No pull-up/pull-down resistors

I/O port

 

 

 

 

Port A

Input mode

No pull-up/pull-down resistors

I/O port

 

 

 

 

Port 0 (P0)

4-bit CMOS tri-state I/O port.

Table 3-1-2 Port 0 Functions

Pin Name

Type

Dual Function

Description

 

 

 

 

P00 to P02

I/O

SBO0(TXD),

Each bit can be set individually as either an input or

P06

 

SBI0(RXD),

output by the P0DIR register. A pull-up resistor for each

 

 

SBT0

bit can be selected individually by the P0PLU register.

 

 

BUZZER

At reset, the input mode is selected and pull-up resistors

 

 

 

are disabled (high impedance output).

 

 

 

 

38 Overview

Page 52
Image 52
Panasonic MN101C00 user manual Status When Port Is Reset single-chip mode, Port 0 P0, Port 0 Functions