CHAPTER 4 PORT FUNCTIONS
User’s Manual U17446EJ3V1UD
65
(2) Port registers (P0, P2, P3, P4, P12, P13)
These registers are used to write data to be output from the corresponding port pin to an external device
connected to the chip.
When a port register is read, the pin level is read in the input mode, and the value of the output latch of the
port is read in the output mode.
P00 to P03, P20 to P23, P30 to P34, P40 to P47, P120 to P123, and P130 are set by using a 1-bit or 8-bit
memory manipulation instruction.
Generation of reset signal sets these registers to 00H.
Figure 4-16. Format of Port Register
Address: FF00H After reset: 00H (Output latch) R/W
Symbol
7 6 5 4 3 2 1 0
P0 0 0 0 0
P03
P02
P01
P00
Address: FF02H After reset: 00H (Output latch) R/W
Symbol
7 6 5 4 3 2 1 0
P2 0 0 0 0
P23
P22
P21
P20
Address: FF03H After reset: 00H
Note
(Output latch) R/W
Note
Symbol
7 6 5 4 3 2 1 0
P3 0 0 0
P34
P33
P32
P31
P30
Address: FF04H After reset: 00H (Output latch) R/W
Symbol
7 6 5 4 3 2 1 0
P4 P47 P46 P45 P44 P43 P42 P41 P40
Address: FF0CH After reset: 00H (Output latch) R/W
Symbol
7 6 5 4 3 2 1 0
P12
0 0 0 0
P123
P122
P121
P120
Address: FF0DH After reset: 00H (Output latch) R/W
Symbol
7 6 5 4 3 2 1 0
P13
0 0 0 0 0 0 0
P130
m = 0, 2, 3, 4, 12, or 13; n = 0-7
Pmn
Controls of output data (in output mode)
Input data read (in input mode)
0
Output 0
Input low level
1
Output 1
Input high level
Note
Because P34 is read-only, its reset value is undefined.
Содержание 78K0S/KB1+
Страница 2: ...User s Manual U17446EJ3V1UD 2 MEMO ...