15.8 INTn Pin Interrupts
PIC18(L)F26/45/46K40 devices have 3 external interrupt sources which can be assigned to any pin on PORTA and PORTB
using PPS. The external interrupt sources are edge-triggered. If the corresponding INTxEDG
bit in the INTCON register is set (= 1
), the interrupt is triggered by a rising edge. It the bit is clear, the
trigger is on the falling edge.
All external interrupts (INT0, INT1, INT2) can wake up the processor from Idle or Sleep modes if bit INTxE was set prior to going into those modes. If the Global Interrupt Enable bit (GIE/GIEH) is set, the processor will branch to the interrupt vector following wake-up.
Interrupt priority is determined by the value contained in the corresponding interrupt priority bit (INT0P, INT1P, INT2P) of the IPR0 register.