mg84fl54b Megawin Technology, mg84fl54b Datasheet - Page 17

no-image

mg84fl54b

Manufacturer Part Number
mg84fl54b
Description
Full-speed Usb Micro-controller
Manufacturer
Megawin Technology
Datasheet
9. Configurable I/O Ports
9.1. Port Configurations
The device has five I/O ports, Port 0 ~ Port 4. All the port pins can be individually and independently configured
to one of four modes: quasi-bidirectional (standard 8051 I/O port), push-pull output, open-drain output or input-
only (high-impedance). Each port pin is equipped with a Schmitt-triggered input to improve input noise rejection.
Each port has two configuration registers, PxM0 and PxM1, to configure the I/O type for each port pin. Where,
x=0~4.
Table : Port Configuration Settings
Where x=0~4 (port number), and y=0~7 (port pin). The registers PxM0 and PxM1 are listed below.
P0M0 (Address=93H, Port 0 Mode Register 0)
P0M1 (Address=94H, Port 0 Mode Register 1)
P1M0 (Address=91H, Port 1 Mode Register 0)
P1M1 (Address=92H, Port 1 Mode Register 1)
P2M0 (Address=95H, Port 2 Mode Register 0)
P2M1 (Address=96H, Port 2 Mode Register 1)
P3M0 (Address=B1H, Port 3 Mode Register 0)
P3M1 (Address=B2H, Port 3 Mode Register 1)
MEGAWIN
P0M0.7
P0M1.7
P1M0.7
P1M1.7
P2M0.7
P2M1.7
P3M0.7
P3M1.7
PxM0.y
7
7
7
7
7
7
7
7
0
0
1
1
P0M0.6
P0M1.6
P1M0.6
P1M1.6
P2M0.6
P2M1.6
P3M0.6
P3M1.6
6
6
6
6
6
6
6
6
PxM1.y
0
1
0
1
P0M0.5
P0M1.5
P1M0.5
P1M1.5
P2M0.5
P2M1.5
P3M0.5
P3M1.5
5
5
5
5
5
5
5
5
Input-Only (High Impedance, Hi-Z)
P0M0.4
P0M1.4
P1M0.4
P1M1.4
P2M0.4
P2M1.4
P3M0.4
P3M1.4
Open-Drain Output
4
4
4
4
4
4
4
4
Quasi-bidirectional
Push-Pull Output
MG84FL54B Data sheet
Port Mode
P0M0.3
P0M1.3
P1M0.3
P1M1.3
P2M0.3
P2M1.3
P3M0.3
P3M1.3
3
3
3
3
3
3
3
3
P0M0.2
P0M1.2
P1M0.2
P1M1.2
P2M0.2
P2M1.2
P3M0.2
P3M1.2
2
2
2
2
2
2
2
2
P0M0.1
P0M1.1
P1M0.1
P1M1.1
P2M0.1
P2M1.1
P3M0.1
P3M1.1
1
1
1
1
1
1
1
1
P0M0.0
P0M1.0
P1M0.0
P1M1.0
P2M0.0
P2M1.0
P3M0.0
P3M1.0
0
0
0
0
0
0
0
0
17

Related parts for mg84fl54b