Extint3 and GPIO Interrupts

Started by prab...@yahoo.co.in August 11, 2010
Hi all,
In LPC236x series,I have to support GPIO interrupts for two pins(in port 0 or port 2).I have also supported P2.13 as normal GPIO.Is it possible to support both features simultaneously??

Because,EINT3 channel is shared with GPIO interrupts.So i am assuming i have
to configure p2.13 as external interrupt for supporting GPIO interrupt.If so,How can i support both features???

If i missed any point let me know??
Thanks,

An Engineer's Guide to the LPC2100 Series

Hi

Each port on P0 and P2 can generate a rising of falling edge interrupt - this is however only the case when these are programmed on a pin by pin basis.

The port change interrupts share the EINT3 interrupt vector.

If P2.13 is configured as EINT3 it will generate interrupts according to its mask (which can also include level sensitive interrupts, which the port change interrupts can't do).

If P2.13 is left as GPIO it can either be used as state change interrupt or left as non-interrupt generating GPIO.

When handing EINT3 IRQ the code has to check whether the source is from EINT3, from a port 0 change or from a port 2 change. It can use the following registers to identify which source (or sources) caused the IRQ and then handle the one(s) which are pending:
EXTINT (for possible EINT3)
IOIntStatus (for possible port 0 and port 2 sources)

In the case of port changes, the following register then indicate exactly which pin change caused the IRQ:
IO0IntStatR - rising edge pins detected on port 0
IO0IntStatF - falling edge pins detected on port 0
IO2IntStatR - rising edge pins detected on port 2
IO2IntStatF - falling edge pins detected on port 2
Therefore there should be complete flexibility.

Regards

Mark

http://www.uTasker.com

--- In l..., prabuisin@... wrote:
>
> Hi all,
> In LPC236x series,I have to support GPIO interrupts for two pins(in port 0 or port 2).I have also supported P2.13 as normal GPIO.Is it possible to support both features simultaneously??
>
> Because,EINT3 channel is shared with GPIO interrupts.So i am assuming i have
> to configure p2.13 as external interrupt for supporting GPIO interrupt.If so,How can i support both features???
>
> If i missed any point let me know??
> Thanks,
>