Jump to main content

##

# 3.18.9 Enhanced Vectored Interrupt Controller (EVIC)

PIC32MZ EF devices generate interrupt requests in response to interrupt events from peripheral modules. The Interrupt Controller module exists outside of the CPU and prioritizes the interrupt events before presenting them to the CPU.

The Interrupt Controller module includes the following features:

- Up to 213 interrupt sources and vectors with dedicated programmable offsets, eliminating the need for redirection

- Single and multi-vector mode operations

- Five external interrupts with edge polarity control

- Interrupt proximity timer

- Seven user-selectable priority levels for each vector

- Four user-selectable sub-priority levels within each priority

- Seven shadow register sets that can be used for any priority level, eliminating software context switch and reducing interrupt latency

- Software can generate any interrupt

## Using The Library

## Library Interface

Enhanced Vectored Interrupt Controller peripheral library provides the following interfaces:

Functions

Name | Description
--- | ---
EVIC_Initialize | Configures and initializes the interrupt subsystem
EVIC_SourceEnable | Enables the interrupt source
EVIC_SourceDisable | Disables the interrupt source
EVIC_SourceIsEnabled | Gets the enable state of the interrupt source
EVIC_SourceStatusGet | Returns the status of the interrupt flag for the selected source
EVIC_SourceStatusSet | Sets the status of the interrupt flag for the selected source
EVIC_SourceStatusClear | Clears the status of the interrupt flag for the selected source
EVIC_ExternalInterruptCallbackRegister | Allows application to register callback for every external interrupt pin
EVIC_ExternalInterruptEnable | Enables external interrupt on selected external interrupt pins
EVIC_ExternalInterruptDisable | Disables external interrupt on selected external interrupt pins

Data types and constants

Name | Type | Description
--- | --- | ---
INT_SOURCE | Enum | Identifies interrupt sources
EXTERNAL_INT_PIN | Enum | Identifies the active external interrupt pins
EXTERNAL_INT_PIN_CALLBACK | Typedef | Pointer to a external Pin-Event handler function