We have looked at the basics of AVR Interrupts, now let us go ahead and use the External Interrupts feature on the AVR MCUs.
Steps to configure the Interrupts:
Contents
The Registers
General Interrupt Control Register (GICR)
7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
---|---|---|---|---|---|---|---|
INT1 | INT0 | INT2 | - | - | - | IVSEL | IVCE |
General Interrupt Flag Register(GIFR)
MCU Control Register (MCUCR)
We will connect two switches to the two interrupt pins and show the status on a LCD. The connections are shown in the image below.