This library allows you to:
- Enable, disable and prioritize a source that may interrupt the core operation
- Identify the source of an interrupt request or exception, usually generated by a peripheral
- Control the edge transition (high-to-low or low-to-high) on which the interrupts are generated
- Associate a programmable priority with the interrupt source
Description of Hardware Controlled by this Library
This library provides a low-level abstraction of the Interrupt Controller module on Microchip microcontrollers with a convenient C language interface. It can be used to simplify low-level access to the module without the necessity of interacting directly with the module's registers, thus hiding differences from one microcontroller variant to another.
The Interrupt Controller is a key component of a microcontroller. The Interrupt Controller reduces the numerous peripheral interrupt request signals to a single interrupt request signal to the microcontroller core.
The key features present on an Interrupt Controller are:
- Interrupt source configuration: Provides the ability to enable, disable, and prioritize a source that may interrupt the core
- Interrupt status flags: Identifies the source of an interrupt request or exception, usually generated by a peripheral
The interrupt will be sent to the core only if the source is enabled to generate an interrupt and interrupts have been enabled (if supported). Sources will be prioritized so that the highest priority interrupt will be sent to the core if multiple sources cause interrupts at the same time.
Many interrupt controllers also include other optional features:
- Global enable configuration: Controls the generation of any interrupt to the core from the Interrupt Controller
- Choice of edge transition: Controls the edge transition (high-to-low or low-to-high) on which the interrupts are generated
- Priority configuration: Associates a programmable priority with the interrupt source
Interrupts can be handled inside the core in the following ways:
- Vectored: Each interrupt has an associated interrupt handler routine
- Non-vectored: All interrupts have a single (shared) interrupt handler routine. The software determines the interrupt source based on the interrupt status-flags register.
- Combination of vectored and non-vectored: Interrupts combined in groups. Each group has a single common interrupt vector or handler, but there are multiple groups (i.e., multiple vectors). Within a specific vector group, software determines which one in the group sources caused the interrupt.
A microcontroller can support one, or more than one of the these modes.
The library interface routines are divided into various sub-sections, which address one of the blocks or the overall operation of the Interrupt module.
|Library Interface Section||Description|
|General Configuration Functions||Provides setup, configuration, and status interface routines for the overall operation of the Interrupt Controller module|
|Interrupt Source Control Functions||Provides setup and status routines for: 1) Setting up the source enable configuration 2) Setting up the vector priority configuration 3) Querying a source's interrupt status flag|
|Other Status and Control Functions||Provides setup and status routines for: 1) Global interrupt enable status 2) Vector number and priority of the current ISR 3) Proximity timer 4)Trap handling|
|Feature Existence Functions||Determine whether certain features are available|
Microchip Technology acquires Atmel