5.2.1 I/O Pins

The PIC16F, PIC18F and PIC32CM MCUs provide highly configurable I/O pin controllers that allow individual pin configurations, including interrupt or event generation on pin changes, and peripheral multiplexing for flexible hardware designs. Table 5-9 provides a comparison of features between PIC16F, PIC18F and PIC32CM.

Table 5-9. PIC16F, PIC18F and PIC32CM I/O Features
FeaturePIC16FPIC18FPIC32CM
Port Group SizeUp to eight pins per PORTUp to eight pins per PORTUp to 32 pins per PORT
Pin MultiplexingPeripheral Pin Select (PPS) or Alternate Pin Function Control (APFCON) for digital signal remapping

Analog functions are generally fixed to specific pins

Peripheral Pin Select (PPS) for digital signal remapping

Analog functions are generally fixed to specific pins

Software-controlled, highly flexible with Peripheral Multiplexing (PMUX)
Read-Modify-Write (RMW) Handled through Data Latch (LATx)Handled through Data Latch (LATx)Atomic RMW through 8-bit/16-bit/32-bit writes
Input Sensing/InterruptsConfigurable input sampling

Interrupt-on-Change (IOC)

Configurable input sampling IOCConfigurable input sampling IOC
Voltage DomainsNo native MVIO

All pins share the same supply

Single VDD

Multi-Voltage I/O (MVIO) support for certain device families

Multi-Voltage I/O (MVIO) support for certain device families:

A subset of pins can use separate VDDIO2 supplies

Supply Status Monitoring

Through ADC/AC

Through ADC/AC

MVIO: VDDIO2 status bit interrupt/event

Through ADC/AC

MVIO: VDDIO2 status bit interrupt/event

Peripheral OverrideSupportedSupportedSupported
I/O Bus AccessSingle-cycle access available for SFRs via the Access BankSingle-cycle access available for SFRs via the Access BankAHB/APB bridge

Arm® single-cycle IOBUS

Output Driver Options

Push-pull

Open-drain control

Slew Rate control

Configurable driver strength

Specialized Pad controls

Signal Routing Port (SRPORT)

Push-pull

Open-drain control

Slew Rate control

Configurable driver strength

Specialized Pad controls

Signal Routing Port (SRPORT)

Push-pull

Open-drain control

Slew rate control

Tri-state

Configurable driver strength

High-sink pins

Input Buffer ControlSupportedSupportedSupported
Pin ConfigurationTRIS registers (input/output)TRIS registers (input/output)PORT registers, advanced configuration
Event SystemN/AN/AIntegrated with the pin controller
Debounce/FilteringN/AN/AAvailable on some pins