English
Language : 

XMEGAA Datasheet, PDF (120/375 Pages) ATMEL Corporation – 8-bit XMEGAA Microcontroller
XMEGA A
12.7
Port Interrupt
Each port has two interrupt vectors, and it is configurable which pins on the port that can be
used to trigger each interrupt request. Port interrupts must be enabled before they can be used.
Which sense configurations that can be used to generate interrupts is dependent on whether
synchronous or asynchronous input sensing is used.
For synchronous sensing, all sense configurations can be used to generate interrupts. For edge
detection, the changed pin value must be sampled once by the peripheral clock for an interrupt
request to be generated.
For asynchronous sensing, only port pin 2 on each port has full asynchronous sense support.
This means that for edge detection, pin 2 will detect and latch any edge and it will always trigger
an interrupt request. The other port pins have limited asynchronous sense support. This means
that for edge detection the changed value must be held until the device wakes up and a clock is
present. If the pin value returns to its initial value before the end of the device start-up time, the
device will still wake up, but no interrupt request will be generated.
A low level can always be detected by all pins, regardless of a peripheral clock being present or
not. If a pin is configured for low level sensing, the interrupt will trigger as long as the pin is held
low. In active mode the low level must be kept until the completion of the currently executing
instructions for an interrupt to be generated. In all sleep modes the low level must be kept until
the end of the device start-up time for an interrupt to be generated. If the low level disappears
before the end of the start-up time, the device will still wake up, but no interrupt will be
generated.
Table 12-1, Table 12-2, and Table 12-3 on page 121 summarizes when interrupts can be trig-
gered for the various input sense configurations.
Table 12-1. Synchronous sense support
Sense settings
Supported
Rising edge
Yes
Falling edge
Yes
Both edges
Yes
Low level
Yes
Interrupt description
Always Triggered
Always Triggered
Always Triggered
Pin-level must be kept unchanged.
Table 12-2. Full asynchronous sense support
Sense settings
Supported
Interrupt description
Rising edge
Yes
Always Triggered
Falling edge
Yes
Always Triggered
Both edges
Yes
Always Triggered
Low level
Yes
Pin-level must be kept unchanged.
8077B–AVR–06/08
120