<?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>Is SD with WDT IRQ set to priority-zero a problem?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/21417/is-sd-with-wdt-irq-set-to-priority-zero-a-problem</link><description>The basic question is: if I initialize the SD and then forcibly change the priority of the WDT IRQ to zero via NVIC_EnableIRQ(), will that cause a problem? 
 I know you don&amp;#39;t normally want to do anything which might preempt the SD&amp;#39;s radio handler...</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 18 Apr 2017 15:03:54 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/21417/is-sd-with-wdt-irq-set-to-priority-zero-a-problem" /><item><title>RE: Is SD with WDT IRQ set to priority-zero a problem?</title><link>https://devzone.nordicsemi.com/thread/83996?ContentTypeID=1</link><pubDate>Tue, 18 Apr 2017 15:03:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4d9e1012-32ec-4c69-bd1e-136fb845cfa6</guid><dc:creator>MarcF</dc:creator><description>&lt;p&gt;Yes... the goal of setting the WDT to priority-zero is exactly that: maximize the amount of time I have during the 2 LFCLK cycles before the system resets in order to clean things up as best I can.  I just wanted to make sure there wasn&amp;#39;t a hidden reason that I shouldn&amp;#39;t do it.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is SD with WDT IRQ set to priority-zero a problem?</title><link>https://devzone.nordicsemi.com/thread/83995?ContentTypeID=1</link><pubDate>Tue, 18 Apr 2017 09:46:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:00bbb894-d2bb-4afa-9e88-37cee1526314</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;According to the softdevice specification you cannot use priority 0 for application interrupts. That said, I think the WDT interrupt should be an exception to this rule. When you get WDT interrupt, the only possibility is the WDT timeout. So when you get this interrupt, your chip will reset within 2 lfclk cycles. Since the BLE connection will be lost anyways, I think it is safe to imagine that the softdevice assert is of no worry.&lt;/p&gt;
&lt;p&gt;So the conclusion is that you can set WDT interrupt to priority 0 after you have enabled the softdevice. Since it will check the priority of app interrupts when you enable softdevice and it would return with error if it finds illegal interrupt priorities, you should always set WDT priority to zero after softdevice is enabled.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>