<?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>Different IRQ priority levels</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/11289/different-irq-priority-levels</link><description>Hi, 
 system info: 
 
 SDK: v6.0.0.43681 
 S110 V7.0.0 
 nRF51822 Rev.2 
 
 I’m using a ~4ms one shot timer (using the timer library) which is being started in the RADIO_NOTIFICATION_IRQHandler(). In the timer_timeout_handler() I’m starting an</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 14 Jan 2016 16:04:55 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/11289/different-irq-priority-levels" /><item><title>RE: Different IRQ priority levels</title><link>https://devzone.nordicsemi.com/thread/42461?ContentTypeID=1</link><pubDate>Thu, 14 Jan 2016 16:04:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bd8eb477-b297-4cf5-8491-938219e0740f</guid><dc:creator>Omar Al Attar</dc:creator><description>&lt;p&gt;Thank you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Different IRQ priority levels</title><link>https://devzone.nordicsemi.com/thread/42459?ContentTypeID=1</link><pubDate>Thu, 14 Jan 2016 11:47:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:72a4e05b-0a24-4129-af43-28c5b5ebeb01</guid><dc:creator>Stefan Birnir Sverrisson</dc:creator><description>&lt;p&gt;Hi Omar&lt;/p&gt;
&lt;p&gt;To figure out what causes the app_error_handler to be called, enable debugging instead of resetting, as described on &lt;a href="https://devzone.nordicsemi.com/question/60125/my-device-is-freezing-and-restarting/"&gt;this thread&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Want to mention one thing in case you did not notice it. Radio notifications can notify the application both before the start of a BLE radio event and when it finishes. So if you want to sample once per radio event and do it when radio is inactive, it is possible to start it on the radio notification that is triggered when the BLE radio event is finished. How to identify the &amp;quot;radio finished&amp;quot; event is described in the &lt;a href="https://devzone.nordicsemi.com/tutorials/14/"&gt;radio notification tutorial&lt;/a&gt;. If this method suits your purpose, it adds the benefit of not having to enable the timer.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Different IRQ priority levels</title><link>https://devzone.nordicsemi.com/thread/42460?ContentTypeID=1</link><pubDate>Thu, 14 Jan 2016 09:42:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:14caf630-342c-4c9d-a3a2-7930a35f9131</guid><dc:creator>Omar Al Attar</dc:creator><description>&lt;p&gt;Hi Stefan,&lt;/p&gt;
&lt;p&gt;actually the ADC values are correct. I&amp;#39;m using a connection interval of 7.5ms and the timer has a timeout of 4ms as mentioned, so the ADC is always sampling between the connection events, so within the remaining 3.5ms. I&amp;#39;m using notifications by the way.&lt;/p&gt;
&lt;p&gt;What we experienced was a non-systematic call of app_error_handler(), so after I reviewed my firmware, I didn&amp;#39;t find anything unusual but this IRQ priority. At the moment I&amp;#39;m calling NVIC_SystemReset(); in app_error_handler().&lt;/p&gt;
&lt;p&gt;Thanks for the support&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Different IRQ priority levels</title><link>https://devzone.nordicsemi.com/thread/42458?ContentTypeID=1</link><pubDate>Wed, 13 Jan 2016 15:38:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2be66fa9-4623-4288-bd28-246cb132584e</guid><dc:creator>Stefan Birnir Sverrisson</dc:creator><description>&lt;p&gt;Hi Omar&lt;/p&gt;
&lt;p&gt;I would not think that any of those interrups could effect one another. When the radio notification handler triggers, it starts an app timer and the radio notification handler execution ends. The RTC1 (used by app timer library) eventually generates an interrupt to execute the timer handler, which is a separate execution thread with independent priority.&lt;/p&gt;
&lt;p&gt;The same applies when starting the ADC sampling from the timer handler. It should not conflict with the ADC interrupt handler as the ADC interrupt handler is a separate execution thread.&lt;/p&gt;
&lt;p&gt;I suspect though that the interrupts can interrupt one another if the radio notification interrupts fire too frequently. That could cause the app timer to trigger ADC sampling before the former ADC sample is ready.&lt;/p&gt;
&lt;p&gt;Are you experiencing strange ADC output, or what is the problem?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>