<?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>Why does my nRF51822 consume &amp;gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/11/why-does-my-nrf51822-consume-1-ma-in-sleep</link><description>No matter what sleep mode I put my nRF51822 in (system on, idle, system-off), it seems that the base current is above 1 mA. Is this how it&amp;#39;s supposed to be?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 22 Feb 2018 09:52:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/11/why-does-my-nrf51822-consume-1-ma-in-sleep" /><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/121639?ContentTypeID=1</link><pubDate>Thu, 22 Feb 2018 09:52:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6311e37c-a6d2-4e4f-b009-3b84c5f517dc</guid><dc:creator>Ankit</dc:creator><description>&lt;p&gt;Can I achieve the results of &amp;quot;nrfjprog&amp;nbsp;-p&amp;quot; commands by&amp;nbsp;code&amp;nbsp;itself?&lt;br /&gt;I have written following lines in my code, will it&amp;nbsp;result same as&amp;nbsp;&lt;span&gt;&amp;quot;&lt;/span&gt;nrfjprog&lt;span&gt;&amp;nbsp;-p&amp;quot;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;void main()&lt;br /&gt;{&lt;br /&gt;if( ( NRF_UICR-&amp;gt;APPROTECT &amp;amp; 0xFF ) == 0xFF )&lt;br /&gt;{&lt;br /&gt;// enable UICR register write mode&lt;br /&gt;NRF_NVMC-&amp;gt;CONFIG = ( NVMC_CONFIG_WEN_Wen &amp;lt;&amp;lt; NVMC_CONFIG_WEN_Pos );&lt;br /&gt;while( NRF_NVMC-&amp;gt;READY == NVMC_READY_READY_Busy );&lt;/p&gt;
&lt;p&gt;// disable debug mode&lt;br /&gt;NRF_UICR-&amp;gt;APPROTECT = 0;&lt;/p&gt;
&lt;p&gt;// disable UICR register write mode&lt;br /&gt;NRF_NVMC-&amp;gt;CONFIG = ( NVMC_CONFIG_WEN_Ren &amp;lt;&amp;lt; NVMC_CONFIG_WEN_Pos );&lt;br /&gt;while( NRF_NVMC-&amp;gt;READY == NVMC_READY_READY_Busy );&lt;/p&gt;
&lt;p&gt;// reboot is required to apply changes&lt;br /&gt;NVIC_SystemReset();&lt;br /&gt;}&lt;br /&gt; &lt;br /&gt;// continue application&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/40?ContentTypeID=1</link><pubDate>Sat, 10 Jun 2017 22:16:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:af629830-aabd-4df6-b708-de0237b1efc9</guid><dc:creator>Gabor Paller</dc:creator><description>&lt;p&gt;This issue almost made me mad but eventually the culprit was indeed the debug mode. I disconnected the debug cable and started the system with external power source but there was a large capacitor on nRF51822&amp;#39;s power line that was able to power the chip until the external power arrived. Thus the system remained in debug mode after programming even though I thought that I switched it off after flashing.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/35?ContentTypeID=1</link><pubDate>Thu, 16 Feb 2017 12:25:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0c8e5c6b-f638-4530-a6a2-e18c4eae35af</guid><dc:creator>wangyong</dc:creator><description>&lt;p&gt;I am currently using GPIOTE pin to wake up system from deep sleep mode. According to PS table 33 GPIOTE requires both 1.2V regulator and HFCLK. Look back to table 32. Which requires 520uA. But I actually measured my power consumption is about 100uA. I am sure HFCLK is not working when system is off. Is there any possibility I can make the power consumption any lower with GPIOTE wakeup feature on? Or  how it suppose to be with 4 GPIOTE wakeups during deep sleep?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/39?ContentTypeID=1</link><pubDate>Mon, 13 Jan 2014 02:25:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cba97793-e3e2-40b8-b0ef-82df4c544bb3</guid><dc:creator>liwentong</dc:creator><description>&lt;p&gt;I also encountered the same situation，the picture is below。ERROR: JLinkArm.dll returned an error condition. Try again. If the condition per
sists, please report the error to Nordic Semiconductor support with the text &amp;quot;pi
n_reset_ignore_pall: return code 8&amp;quot;.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/.PNG"&gt;捕获.PNG&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/38?ContentTypeID=1</link><pubDate>Mon, 06 Jan 2014 07:42:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:594dd571-e2cc-4d11-9f65-51bce596eabe</guid><dc:creator>siming</dc:creator><description>&lt;p&gt;hi,&lt;/p&gt;
&lt;p&gt;I can&amp;#39;t using nrfjprog.exe -p success with this error:
ERROR: JLinkArm.dll returned an error condition. Try again. If the condition per
sists, please report the error to Nordic Semiconductor support with the text &amp;quot;pi
n_reset_ignore_pall: return code 8&amp;quot;.
how it&amp;#39;s supposed to be?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/37?ContentTypeID=1</link><pubDate>Tue, 09 Jul 2013 12:28:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:26fa7dbd-f3b8-4fb9-8b9a-7434121e4d38</guid><dc:creator>Netrom Ello</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I found with the current version of nrfjprog (comes with nRF51 SDK v4.3), I could also trigger a pin reset by using:&lt;/p&gt;
&lt;p&gt;nrfjprog.exe -p&lt;/p&gt;
&lt;p&gt;The device ran in normal mode after that.&lt;/p&gt;
&lt;p&gt;Ello&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/36?ContentTypeID=1</link><pubDate>Tue, 11 Jun 2013 10:51:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0ef4a209-319c-4c5b-a7c6-b4278e2485e1</guid><dc:creator>Per Magnus &amp;#216;sthus</dc:creator><description>&lt;blockquote&gt;
&lt;p&gt;The debug interface of the chip will stay enabled after having flashed it, and will not be disabled until a full reset (i.e. removing and re-applying voltage to the chip).&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;A pin-reset will also disable the debug interface, but by default pin-reset is disabled in debug mode. To enable pin-reset again, you can send this command in JLink:
w4 40000544 1 // Write 1 to the POWER.RESET register&lt;/p&gt;
&lt;p&gt;Then hold SWCLK and nRESET low for over 100 us. (I don&amp;#39;t know if the &amp;#39;r&amp;#39; command in JLink will work..).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Why does my nRF51822 consume &gt; 1 mA in sleep?</title><link>https://devzone.nordicsemi.com/thread/34?ContentTypeID=1</link><pubDate>Mon, 10 Jun 2013 20:37:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43707db1-5a08-43ed-a9ff-875afd62bcb9</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;No, this is most definitely not a reasonable measurement. When in system on, idle, the consumption should be ~3 µA, and in system off &amp;lt; 1 µA. These numbers are given in table 23 (Power management) in the &lt;a href="https://www.nordicsemi.com/eng/content/search?SearchText=nrf51822+ps"&gt;nRF51822 PS&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;There is primarily one suspect when seeing consumption above 1 mA in sleep, and that is the debug interface. The debug interface of the chip will stay enabled after having flashed it, and will not be disabled until a full reset (i.e. removing and re-applying voltage to the chip).&lt;/p&gt;
&lt;p&gt;If this does not help, you should consider which peripherals you have running. Table 24 in the PS shows which peripherals needs which clock sources and regulators, and as a rule-of-thumb, anything that requires the 16 MHz clock is high power, while everything else is low-power. In general, as many peripherals as possible should be powered down while in sleep, by setting their ENABLE registers to 0 or similar.&lt;/p&gt;
&lt;p&gt;Edit: To understand power management on the nRF51 series devices a little better, &lt;a href="https://devzone.nordicsemi.com/index.php/what-is-the-power-and-clock-model-of-peripheral-in-nrf51"&gt;this question&lt;/a&gt; may also be useful.&lt;/p&gt;
&lt;p&gt;Also, as Ello points out below, you can do a pin-reset to disable the debug interface by using&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;
nrfjprog -p

&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>