1.24.9.20 GPIO_PinInterruptEnable Function

C

The prototype of this function varies based on device family. Refer to the generated header file for the actual prototype to be used.

void GPIO_PinInterruptEnable(CN_PIN cnPin)
void GPIO_PinInterruptEnable(GPIO_PIN pin)

Summary

Enables CN interrupt on selected pin.

Description

This function enables CN interrupt on selected pin.

Precondition

Corresponding pin must be configured in interrupt mode in MHC Pin Manager.

Parameters

Param Description
cnPin One or multiple CN pins ORed from the enum CN_PIN
pin One of the IO pins from the enum GPIO_PIN

Returns

None.

Example

Example of this function varies based on device family. Refer to the one which is applicable for the device being used.

// Enable CN interrupt for CN8 and CN10 pins
GPIO_PinInterruptEnable(CN8_PIN | CN10_PIN);
// Enables CN interrupt for RB3 pin
GPIO_PinInterruptEnable(GPIO_PIN_RB3);

Remarks

None.