<?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>APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/55814/app-timer-interrupt-and-gpiote-interrupt-doubts</link><description>HI , 
 
 In our project we are using multiple gpiote and app timer interrupt. 
 SDK we are using is 15.3 
 
 
 DOUBTS 
 
 If both gpiote and app timer interrupt trigger simultaneously(at same time) ,code execution enter to which handler first gpiote or</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 19 Dec 2019 05:45:18 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/55814/app-timer-interrupt-and-gpiote-interrupt-doubts" /><item><title>RE: APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/thread/226263?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2019 05:45:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b9c75b59-9627-4d2c-a6e3-d2531858e2e6</guid><dc:creator>NANDHU</dc:creator><description>&lt;p&gt;THANKS BJRON&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/thread/226262?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 08:54:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ae70e88a-37a3-4593-b67f-bb0f70aaa912</guid><dc:creator>NANDHU</dc:creator><description>&lt;p&gt;thanks&amp;nbsp; bjron.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/thread/226261?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 08:51:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a9c0e95e-b7a3-4bd5-b06f-6a56e5965b74</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;It the timer has priority 7 and gpiote has priority 6 then the following will be&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If the gpiote interrupt occurs while the timer IRQ handler is being executed, then the GPIOTE interrupt will pre-empt the timer IRQ handler as it has a higher priority and execute until its finished. Then execution will be returned to the timer interrupt handler.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;If the timer interrupt occurs while the GPIOTE IRQ handler is being executed, then the GPIOTE IRQ handler will execute until its finished and then the timer IRQ handler will be executed afterwards as it has lower priority.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Best regards&lt;/p&gt;
&lt;p&gt;Bjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/thread/226260?ContentTypeID=1</link><pubDate>Wed, 18 Dec 2019 03:41:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e5f01d7b-94e1-4bac-b630-d7f2f58c7ea0</guid><dc:creator>NANDHU</dc:creator><description>&lt;p&gt;So you are saying, if both interrupt trigger at same time both will execute one after another ,Is it right?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If timer priority is 7 and gpiote priority is 6 is the same scenario will happen or not?&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: APP TIMER INTERRUPT AND  GPIOTE INTERRUPT DOUBTS</title><link>https://devzone.nordicsemi.com/thread/226259?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2019 13:59:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6afb97c5-44b0-4f14-b1a4-13db01aabf14</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Hi Nandu,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user=""]If both&amp;nbsp; gpiote and&amp;nbsp; app timer interrupt trigger simultaneously(at same time) ,code execution enter to which handler first gpiote or timer (note :- both priority are same)?[/quote]
&lt;p&gt;From the nRF&amp;#39;s perspective, one of the interrupts will occurs first and then the second will occur while the IRQ handler of the first is being executed.&amp;nbsp; If this happens then a pending IRQ flag will be set in the nested vectored interrupt controller (NVIC) of the Arm Cortex M4,&amp;nbsp;since both have the same IRQ priority the second interrupt will not pre-emt the first one. When the IRQ handler of the first interrupt returns, then the CPU will check if there is a pending IRQ and process that before returning to mains context.&amp;nbsp;&lt;/p&gt;
[quote user=""]if both &lt;span&gt;gpiote and&amp;nbsp; app timer interrupt trigger&lt;/span&gt; simultaneously,Is any of these interrupt ignore if so which one?[/quote]
&lt;p&gt;&amp;nbsp;See the first answer.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards&lt;/p&gt;
&lt;p&gt;Bjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>