![NEC V850/SC1 Скачать руководство пользователя страница 182](http://html.mh-extra.com/html/nec/v850-sc1/v850-sc1_user-manual_248178182.webp)
CHAPTER 5 PORT FUNCTIONS
User’s Manual U15109EJ3V0UD
180
5.2.12 Port 13
Port 13 is a 4-bit I/O port for which I/O settings can be controlled in 1-bit units.
After reset:
00H
R/W
Address: FFFFF01AH
7
6
5
4
3
2
1
0
P13
0
0
0
0
P133
P132
P131
P130
P13n
Control of output data (in output mode) (n = 0 to 3)
0
Outputs 0
1
Outputs 1
Remark
In input mode:
When P13 is read, the pin levels at that time are read. Writing to P13 writes the
values to that port. This does not affect the input pins.
In output mode: When P13 is read, the values of P13 are read. Writing to P13 writes the values to
that port, and those values are immediately output.
(1) Function of P13 pins
Port 13 is a 4-bit port for which I/O settings can be controlled in 1-bit units. I/O settings are controlled via the port
13 mode register (PM13).
In output mode, the values set to each bit are output to port 13 (P13).
When using this port in input mode, the pin statuses can be read by reading P13. Also, the values of P13 (output
latch) can be read by reading P13 while in output mode.
When a reset is input, the settings are initialized to input mode.
(2) Control register
(a) Port 13 mode register (PM13)
PM13 can be read/written in 8- or 1-bit units.
After reset:
0FH
R/W
Address: FFFFF03AH
7
6
5
4
3
2
1
0
PM13
0
0
0
0
PM133
PM132
PM131
PM130
PM13n
Control of I/O mode (n = 0 to 3)
0
Output mode
1
Input mode