SN8P1829
8-Bit MCU build-in 12-bit ADC + PGIA + Charge-pump Reg 128 dots LCD driver
SONiX TECHNOLOGY CO., LTD
Page 109
Version 1.0
I/O PORT DATA REGISTER
P0 initial value = xxxx xxxx
0D0H
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
P0
- - - - - -
P01
P00
- - - - - - R R
P1 initial value = xxxx xxxx
0D1H
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
P1
- - - -
P13
P12
P11
P10
- - - -
R/W
R/W
R/W
R/W
P2 initial value = xxxx xxxx
0D2H
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
P2
P27 P26 P25 P24 P23 P22 P21 P20
R R R R R R R R
P5 initial value = xxx0 0000
0D5H
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
P5
-
-
- P54 P53 P52 P51 P50
-
-
- R/W R/W R/W R/W R/W
Example: Read data from input port.
B0MOV
A, P0
; Read data from Port 0
B0MOV
A, P1
; Read data from Port 1
B0MOV
A, P5
; Read data from Port 5
Example: Write data to output port.
MOV
A, #55H
; Write data 55H to Port 1 and Port 5
B0MOV
P1,
A
B0MOV
P5,
A
Example: Write one bit data to output port.
B0BSET
P1.3
; Set P1.3 to be “1”.
B0BCLR
P1.3
; Set P1.3 and P5.1 to be “0”.
B0BCLR
P5.1
Example: Port bit test.
B0BTS1
P0.0
; Bit test 1 for P0.0
.
B0BTS0
P1.1
; Bit test 0 for P1.1