<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Maximum number of interrupt enabled pins?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/650/maximum-number-of-interrupt-enabled-pins</link><description>Hi, 
 Sorry for the noob questions but I&amp;#39;m trying to understand the GPIOTE abstraction and terminology, specifically the events, interrupts and tasks. My understanding is that GPIOTE can have events (signal transitions on input pins) generating interrupts</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 22 Oct 2013 08:00:10 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/650/maximum-number-of-interrupt-enabled-pins" /><item><title>RE: Maximum number of interrupt enabled pins?</title><link>https://devzone.nordicsemi.com/thread/3313?ContentTypeID=1</link><pubDate>Tue, 22 Oct 2013 08:00:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1d0bb233-d5a4-4054-a244-634574b42308</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Florin,&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;As discussed in the other case, SENSE is level triggered, not edge triggered. So if you have one pin stays high, PORT even will always be on and can not trigger a new interrupt until all 2 pin are low.
In this case either do polling as suggested in the other case or you will have to change the SENSE level of the pin that always on to low to detect the other pin.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;The PORT event is only generated when DETECT signal move from low to high. The DETECT signal is shared between all pins. So DETECT signal will remain high until all pins clears SENSE (both pins to low level as in your example).&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;So if both pins remains high, PORT event is triggered only once, at the beginning when first pin changed from low to high or when PORT event is enabled, if the pin is already high before.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Maximum number of interrupt enabled pins?</title><link>https://devzone.nordicsemi.com/thread/3312?ContentTypeID=1</link><pubDate>Fri, 18 Oct 2013 13:01:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e2c9ea46-d2a4-41af-8b35-781cfa546fb9</guid><dc:creator>Florin</dc:creator><description>&lt;p&gt;Thanks for the detailed answer!&lt;/p&gt;
&lt;p&gt;On the PORT even I still have two questions:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;If I configure two pins to sense a high level, how can I detect which pin raised the interrupt if one pin stays high the whole time while the other one transitions? (specifically, NRF_GPIO-&amp;gt;IN will report both pins to 1, how can I tell them apart?)&lt;/li&gt;
&lt;li&gt;What if both pins remain high, are interrupts still generated or are they generated on transitions only (as Fig.15 pg 55 of the Reference Manual suggests)?&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;There is another discussion here &lt;a target="_blank" href="https://devzone.nordicsemi.com/index.php/nrf51422-sense-mechanism-detect-more-than-one-pin" rel="nofollow"&gt;https://devzone.nordicsemi.com/index.php/nrf51422-sense-mechanism-detect-more-than-one-pin&lt;/a&gt;  but it&amp;#39;s still not clear to me...&lt;/p&gt;
&lt;p&gt;Thanks again!
florin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Maximum number of interrupt enabled pins?</title><link>https://devzone.nordicsemi.com/thread/3311?ContentTypeID=1</link><pubDate>Fri, 18 Oct 2013 09:22:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dbe040d8-1045-487a-8727-6de2333c5664</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;There are 2 type of event for GPIO pins: port event and pin events. You can find the definition at section 14.1.1 and 14.1.2&lt;/p&gt;
&lt;p&gt;Basically for PIN events you can have maximum 4 pin events, each for one GPIO pin (so max 4 pins at a time) and you can detect which pin cause the event.
PORT event, on the other hand, can be set for all GPIO pins at the same time, with the DETECT signal (sense mechanism).&lt;/p&gt;
&lt;p&gt;You will get the PORT event when any pin issues the DETECT signal. You will not be be able to directly detect the pin, but can pass through all the pins that enabled SENSE and read the value of each pin to detect which causes the signal.&lt;/p&gt;
&lt;p&gt;One main difference that worth mentioning is that PORT event and SENSE mechanism don&amp;#39;t require 16MHz oscillator which mean you can have very low power consumption, when PIN event, when enabled, will consume about 1mA.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>