Ports Peripheral Library Interface for Harmony v2

Detailed descriptions for this library can be found on MPLAB® Harmony v2 Help and Documentation.
( found in the <harmony install directory>/doc folder)

Port Pin Functions

Function Name Description
PLIB_PORTS_PinClear Clears the selected digital pin/latch
PLIB_PORTS_PinDirectionInputSet Makes the selected pin direction input
PLIB_PORTS_PinDirectionOutputSet Makes the selected pin direction output
PLIB_PORTS_PinGet Reads/Gets data from the selected digital pin
PLIB_PORTS_PinModeSelect Enables the selected pin as analog or digital
PLIB_PORTS_PinSet Sets the selected digital pin/latch
PLIB_PORTS_PinToggle Toggles the selected digital pin/latch
PLIB_PORTS_PinWrite Writes the selected digital pin/latch
PLIB_PORTS_PinModePerPortSelect Enables the selected port pin as analog or digital
PLIB_PORTS_PinGetLatched Reads/Gets data from the selected latch

Port Functions

Function Name Description
PLIB_PORTS_Clear Clears the selected digital port/latch bits
PLIB_PORTS_DirectionGet Reads the direction of the selected digital port
PLIB_PORTS_DirectionInputSet Makes the selected pins direction input
PLIB_PORTS_DirectionOutputSet Makes the selected pins direction output
PLIB_PORTS_PinOpenDrainDisable Disables the open drain functionality for the selected pin
PLIB_PORTS_PinOpenDrainEnable Enables the open drain functionality for the selected pin
PLIB_PORTS_Read Reads the selected digital port
PLIB_PORTS_Set Sets the selected bits of the port
PLIB_PORTS_Toggle Toggles the selected digital port/latch
PLIB_PORTS_Write Writes the selected digital port/latch
PLIB_PORTS_OpenDrainDisable Disables the open drain functionality for the selected port
PLIB_PORTS_OpenDrainEnable Enables the open drain functionality for the selected port pins
PLIB_PORTS_ReadLatched Reads/Gets data from the selected Latch
PLIB_PORTS_ChannelModeSelect Enables the selected channel pins as analog or digital

Peripheral Pin Select Functions

Function Name Description
PLIB_PORTS_RemapInput Input function remapping
PLIB_PORTS_RemapOutput Output function remapping

Change Notification Functions

Function Name Description
PLIB_PORTS_ChangeNoticeDisable Global Change Notice disable
PLIB_PORTS_ChangeNoticeEnable Global Change Notice enable
PLIB_PORTS_ChangeNoticeInIdleDisable CPU Idle halts the Change Notice operation
PLIB_PORTS_ChangeNoticeInIdleEnable CPU Idle mode does not affect Change Notice operation
PLIB_PORTS_ChangeNoticeInIdlePerPortDisable Change Notification halts in Idle mode for selected channel
PLIB_PORTS_ChangeNoticeInIdlePerPortEnable Allows CN to be working in Idle mode for selected channel
PLIB_PORTS_ChangeNoticePerPortHasOccured checks the status of change on the pin
PLIB_PORTS_ChangeNoticePerPortTurnOff Disables the change notification for selected port
PLIB_PORTS_ChangeNoticePerPortTurnOn Enables the change notification for selected port
PLIB_PORTS_ChangeNoticePullDownPerPortDisable Disables the pull down for selected change notice pins
PLIB_PORTS_ChangeNoticePullDownPerPortEnable Enables the pull down for selected change notice pins
PLIB_PORTS_ChangeNoticePullUpDisable Disable pull-up on input change
PLIB_PORTS_ChangeNoticePullUpEnable Enable pull-up on input change
PLIB_PORTS_ChangeNoticePullUpPerPortDisable Disables weak pull-up for the selected pin
PLIB_PORTS_ChangeNoticePullUpPerPortEnable Enables the pull up for selected change notice pins
PLIB_PORTS_PinChangeNoticeDisable Port pin Change Notice disable
PLIB_PORTS_PinChangeNoticeEnable Port pin Change Notice interrupt enable
PLIB_PORTS_PinChangeNoticePerPortDisable Disables CN interrupt for the selected pin
PLIB_PORTS_PinChangeNoticePerPortEnable Enables CN interrupt for the selected pin
PLIB_PORTS_ChangeNoticePerPortHasOccurred checks the status of change on the pin
PLIB_PORTS_ChannelChangeNoticeDisable Disables CN interrupt for the selected pins of a channel
PLIB_PORTS_ChannelChangeNoticeEnable Enables CN interrupt for the selected pins of a channel
PLIB_PORTS_ChannelChangeNoticePullDownDisable Disables change notice pull-Down for the selected channel pins
PLIB_PORTS_ChannelChangeNoticePullDownEnable Enables change notice pull-Down for the selected channel pins
PLIB_PORTS_ChannelChangeNoticePullUpDisable Disables change notice pull-up for the selected channel pins
PLIB_PORTS_ChannelChangeNoticePullUpEnable Enables change notice pull-up for the selected channel pins
PLIB_PORTS_AnPinsModeSelect Enables the selected AN pins as analog or digital
PLIB_PORTS_CnPinsDisable Disables CN interrupt for the selected pins of a channel
PLIB_PORTS_CnPinsEnable Enables CN interrupt for the selected pins of a channel
PLIB_PORTS_CnPinsPullUpDisable Disables change notice pull-up for the selected channel pins
PLIB_PORTS_CnPinsPullUpEnable Enables change notice pull-up for the selected channel pins

Feature Existence Functions

Function Name Description
PLIB_PORTS_ExistsChangeNotice Identifies whether the ChangeNotice feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticeInIdle Identifies whether the ChangeNoticeInIdle feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePerPortInIdle Identifies whether the ChangeNoticeInIdlePerPort feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePerPortStatus Identifies whether the ChangeNoticePerPortStatus feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePerPortTurnOn Identifies whether the ChangeNoticePerPortTurnOn feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePullDownPerPort Identifies whether the ChangeNoticePullDownPerPort feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePullUp Identifies whether the ChangeNoticePullup feature exists on the PORTS module
PLIB_PORTS_ExistsChangeNoticePullUpPerPort Identifies whether the ChangeNoticePullUpPerPort feature exists on the PORTS module
PLIB_PORTS_ExistsPinChangeNotice Identifies whether the PinChangeNotice feature exists on the PORTS module
PLIB_PORTS_ExistsPinChangeNoticePerPort Identifies whether the PinChangeNoticePerPort feature exists on the PORTS module
PLIB_PORTS_ExistsPinMode Identifies whether the PinMode feature exists on the PORTS module
PLIB_PORTS_ExistsPinModePerPort Identifies whether the PinModePerPort feature exists on the PORTS module
PLIB_PORTS_ExistsPortsDirection Identifies whether the PortsDirection feature exists on the PORTS module
PLIB_PORTS_ExistsPortsOpenDrain Identifies whether the PortsOpenDrain feature exists on the PORTS module
PLIB_PORTS_ExistsPortsRead Identifies whether the PortsRead feature exists on the PORTS module
PLIB_PORTS_ExistsPortsWrite Identifies whether the PortsWrite feature exists on the PORTS module
PLIB_PORTS_ExistsRemapInput Identifies whether the RemapInput feature exists on the PORTS module
PLIB_PORTS_ExistsRemapOutput Identifies whether the RemapOutput feature exists on the PORTS module
PLIB_PORTS_ExistsLatchRead Identifies whether the LatchRead feature exists on the PORTS module
PLIB_PORTS_ExistsAnPinsMode Identifies whether the AnPinsMode feature exists on the PORTS module

Data Types and Constants

Name Description
PORTS_ANALOG_PIN Data type defining the different analog input pins
PORTS_BIT_POS Lists the constants that hold different PORTS bit positions
PORTS_CHANGE_NOTICE_PIN Data type defining the different Change Notification (CN) pins enumerations
PORTS_CHANNEL Identifies the available Ports channels
PORTS_DATA_MASK Data type defining the PORTS data mask
PORTS_DATA_TYPE Data type defining the PORTS data type
PORTS_MODULE_ID Identifies the available Ports modules
PORTS_PIN_MODE Identifies the available pin modes
PORTS_REMAP_FUNCTION Data type defining the different remap function enumerations
PORTS_REMAP_INPUT_FUNCTION Data type defining the different remap input function enumerations
PORTS_REMAP_INPUT_PIN Data type defining the different Ports I/O input pins enumerations
PORTS_REMAP_OUTPUT_FUNCTION Data type defining the different remap output function enumerations
PORTS_REMAP_OUTPUT_PIN Data type defining the different Ports I/O output pins enumerations
PORTS_REMAP_PIN Data type defining the different remappable input/output enumerations
PORTS_AN_PIN Data type defining the different analog input pins
PORTS_CN_PIN Data type defining the different Change Notification (CN) pins enumerations
© 2024 Microchip Technology, Inc.
Notice: ARM and Cortex are the registered trademarks of ARM Limited in the EU and other countries.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.