<?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>Errata 136</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/62757/errata-136</link><description>Hi, 
 
 I have some questions regarding errata 136. 
 
 I understand that the workaround is to ignore reset reason bits which are not RESETPIN . 
 However, I don&amp;#39;t understand how ~POWER_RESETREAS_RESETPIN_Msk can help us, as the operation makes pin reset</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 25 Jun 2020 15:24:50 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/62757/errata-136" /><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256993?ContentTypeID=1</link><pubDate>Thu, 25 Jun 2020 15:24:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:86f64efb-9add-4dd4-9bfc-216d1c44adb5</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;reset pin will only be set if the reset pin is&amp;nbsp;pulsed, either by a user, or an external IC.&lt;/p&gt;
&lt;p&gt;If watchdog is the only reset source, then you shall be able to detect this in&amp;nbsp;RESETREAS&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256742?ContentTypeID=1</link><pubDate>Wed, 24 Jun 2020 14:29:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3065fb58-b7f1-4fd7-8a41-f5ca84e08e2e</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;So how can I know that reset pin will not be set the next time WDT occurs? How can I recognize WDT reset if errata 136 clears the bit?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256730?ContentTypeID=1</link><pubDate>Wed, 24 Jun 2020 14:04:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:889b4841-6ac5-46e4-9fa5-5ad243f1ac9d</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The workaround will only be applied if this is true:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;if (NRF_POWER-&amp;gt;RESETREAS &amp;amp; POWER_RESETREAS_RESETPIN_Msk){
    NRF_POWER-&amp;gt;RESETREAS =  ~POWER_RESETREAS_RESETPIN_Msk;
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;That should not be true if WDT reset is the only source in RESETREAS. Again, note that this is an accumulate register, meaning that for each reboot, it accumulates and remembers the former reset reason unless the application&amp;nbsp;writes &amp;#39;1&amp;#39; to it.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256565?ContentTypeID=1</link><pubDate>Wed, 24 Jun 2020 06:02:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:299e561e-5511-4a44-b448-ec508077b91e</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;I meant when my device is turning on&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256564?ContentTypeID=1</link><pubDate>Wed, 24 Jun 2020 06:01:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ad4f7b7f-2d13-47da-859b-d8c81ed347d4</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;The problem is as following:&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;After MCU watchdog,&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;SystemInit&lt;/span&gt;() is called and errata 136 workaround is operated.&lt;/p&gt;
&lt;p&gt;After that, when my device is turning of, I&amp;#39;m trying to check the restart reason bit, and I can&amp;#39;t indicate that the reason is watchdog, because watchdog bit is reset due to errate 136 workaround.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;How can I solve that?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256095?ContentTypeID=1</link><pubDate>Mon, 22 Jun 2020 07:02:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6718c54f-ed23-478d-b817-69cfd717d4fc</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>[quote user="Roei"]So regaring watchdog - your suggestion is to clear whole register bits with &lt;span style="background-color:#ffffff;"&gt;0xFFFFFFFF&lt;/span&gt;, in case of watchdog timeout?[/quote]
&lt;p&gt;You can do this if you plan to not check any other sources.&lt;/p&gt;
&lt;p&gt;If you check for other RESETREAS sources; you check the certain bit and clear it (by writing &amp;#39;1&amp;#39; to the source bit position) afterwards.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/256051?ContentTypeID=1</link><pubDate>Sun, 21 Jun 2020 06:03:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d625aa31-d922-4839-9f76-1c92687d9a0c</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;OK,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So regaring watchdog - your suggestion is to clear whole register bits with &lt;span style="background-color:#ffffff;"&gt;0xFFFFFFFF&lt;/span&gt;, in case of watchdog timeout?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/255954?ContentTypeID=1</link><pubDate>Fri, 19 Jun 2020 11:32:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:09f09c35-a05a-4f90-8185-dc764514161b</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>[quote user="Roei"]So the operation &amp;amp; with the reset pin mask will actually tell us if the bit is cleared? [/quote]
&lt;p&gt;No, it will clear all other sources if pin reset is set in RESETREAS register. As the errata explains, other bits can be set when RESETREAS_RESETPIN is set.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/255945?ContentTypeID=1</link><pubDate>Fri, 19 Jun 2020 11:05:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1e40f692-70dc-4a0d-992c-357f11119ca7</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;So the operation &amp;amp; with the reset pin mask will actually tell us if the bit is cleared? That&amp;#39;s the idea?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;And if so - we know that it has been used?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/255942?ContentTypeID=1</link><pubDate>Fri, 19 Jun 2020 10:54:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:98a0a5e8-d020-4350-827f-610e3f56470e</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="Roei"]So the operation&amp;nbsp;&lt;span&gt;&amp;nbsp;if (NRF_POWER-&amp;gt;RESETREAS &amp;amp; POWER_RESETREAS_RESETPIN_Msk)&lt;/span&gt; checks if the bit is cleared? And if so, it makes that bit 0 and the others cleared (1)?[/quote]
&lt;p&gt;It checks if the condition has been met.&lt;/p&gt;
&lt;p&gt;A read of the register will not alter the contents. Only a write to it will do that.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;The errata 136 states that if the reset pin is used, other sources might also be set at the same time. The sequence will ensure that these other resetreas sources are cleared and only the resetpin is set in the register.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="Roei"]I&amp;#39;m using&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;sd_power_reset_reason_get&lt;/span&gt; to get the bitmap, and then operating&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;&amp;amp; POWER_RESETREAS_DOG_Msk&lt;/span&gt; on the reslt, in order to identify watchdog reset. If watchdog was identified, I&amp;#39;m using&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;sd_power_reset_reason_clr(POWER_RESETREAS_DOG_Msk)&lt;/span&gt; to clear the bit.[/quote]
&lt;p&gt;If you see that RESETREAS_DOG_Msk is set in this register, it is likely because the reset reason is due to a watchdog timeout. Try clearing the whole register, as it is accumulative register, meaning it keeps the values. During a debug session, it is quite common to see several reset sources, especially if you are pressing the button from time-to-time, and doing debug-reset from an IDE.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/255904?ContentTypeID=1</link><pubDate>Fri, 19 Jun 2020 08:51:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8e7d8618-7d06-40d6-a71e-ebf5ae73d892</guid><dc:creator>Roei</dc:creator><description>&lt;p&gt;So the operation&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;&amp;nbsp;if (NRF_POWER-&amp;gt;RESETREAS &amp;amp; POWER_RESETREAS_RESETPIN_Msk)&lt;/span&gt; checks if the bit is cleared? And if so, it makes that bit 0 and the others cleared (1)?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m using&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;sd_power_reset_reason_get&lt;/span&gt; to get the bitmap, and then operating&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;&amp;amp; POWER_RESETREAS_DOG_Msk&lt;/span&gt; on the reslt, in order to identify watchdog reset. If watchdog was identified, I&amp;#39;m using&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;sd_power_reset_reason_clr(POWER_RESETREAS_DOG_Msk)&lt;/span&gt; to clear the bit.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Errata 136</title><link>https://devzone.nordicsemi.com/thread/255894?ContentTypeID=1</link><pubDate>Fri, 19 Jun 2020 08:19:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bf439eba-11b2-417e-b039-f632ca3bece1</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user=""]However, I don&amp;#39;t understand how&amp;nbsp;&lt;span style="background-color:#ffffff;color:#474747;float:none;font-family:monospace;font-size:13.33px;font-style:normal;font-weight:400;letter-spacing:normal;text-align:left;text-decoration:none;text-indent:0px;text-transform:none;white-space:pre-wrap;"&gt;~POWER_RESETREAS_RESETPIN_Msk&lt;/span&gt; can help us, as the operation makes pin reset bit 0 and the other bits become 1. Isn&amp;#39;t that the opposite from what we want?[/quote]
&lt;p&gt;The RESETREAS register is cleared by writing &amp;#39;1&amp;#39; to the bit, as shown in the PS:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/power.html?cp=4_2_0_17_8_2#register.RESETREAS"&gt;https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/power.html?cp=4_2_0_17_8_2#register.RESETREAS&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;This will ensure that the RESETPIN_Msk is still held when the application checks the specific bit after the errata workaround has executed.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
[quote user=""]In addition, I had some troubles with implementing watchdog, as&amp;nbsp;&lt;span style="background-color:#ffffff;"&gt;POWER_RESETREAS_DOG_Msk&lt;/span&gt; was always true, until I removed errata 126 fix. Is it possible?[/quote]
&lt;p&gt;Are you clearing the RESETREAS by writing &amp;#39;1&amp;#39; to the source bit?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Kind regards,.&lt;/p&gt;
&lt;p&gt;Håkon&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>