SN8P1700
8-bit micro-controller build-in 12-bit ADC
SONiX TECHNOLOGY CO., LTD
Page 162
Revision 1.93
Example: I/O mode selecting.
CLR
P1M
; Set all ports to be input mode.
CLR
P2M
CLR
P4M
CLR
P5M
MOV
A, #0FFH
; Set all ports to be output mode.
B0MOV
P1M,
A
B0MOV
P2M,
A
B0MOV
P4M,
A
B0MOV
P5M,
A
B0BCLR
P1M.5
; Set P1.5 to be input mode.
B0BSET
P1M.5
; Set P1.5 to be output mode.