<?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>waking from sleep</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/17296/waking-from-sleep</link><description>Hi, 
 I am having some trouble getting the nrf51422 (running the s130 soft device) to wake up after entering sleep mode. I have successfully entered sleep mode using NRF_POWER-&amp;gt;SYSTEMOFF = 1, and sd_power_system_off() (both seem to be effective). However</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 02 Nov 2016 14:43:27 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/17296/waking-from-sleep" /><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66477?ContentTypeID=1</link><pubDate>Wed, 02 Nov 2016 14:43:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:48116bc6-a08a-4383-840c-e655f4ddfaa1</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;Ok, after restarting the whole PCA10028 board 3 times with the power switch, with the &amp;quot;nrf current measurement&amp;quot; jumper closed, the current dropped to about 114 uA,  Is there any way to get this under 10 uA?  I thought this chip should hit &amp;lt;1 uA in systemoff mode (it did with the low power example, using the same code, pin and clock configurations)?  I have been able to get our custom PCB down to ~70 uA in Systemoff by restarting and not initializing the soft-device before the systemoff call, but it still does not restart properly on pin change.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66476?ContentTypeID=1</link><pubDate>Wed, 02 Nov 2016 13:26:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0a66b1dd-ef1e-4104-8f11-13a161771035</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;I tested this on the DK PCA10028 with NRF_POWER-&amp;gt;SYSTEMOFF = 1 and it shows 0.13mA. It is important that you power cycle or do a pin reset after you flash your code to bring the chip out of debug mode. In debug mode the system will be in emulated system off mode where power will not be reduced to minumum.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66474?ContentTypeID=1</link><pubDate>Tue, 01 Nov 2016 15:18:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6b967f61-ae8a-4569-9db6-6f29c3657064</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;Using NRF_POWER-&amp;gt;SYSTEMOFF = 1;, it draws 2.4 mA.  Are there other settings somewhere that I am missing?  I have copied the code from the low current systemoff example, and still get ~2.4 mA.  I am using the external crystal for the LF clock source, and am not advertising or even initializing the soft-device.  I have also tried setting all GPIO to inputs with pulldown, and have reset the device repeatedly to ensure it is not in debug mode (both with the switch and with the current-measurement jumper).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66473?ContentTypeID=1</link><pubDate>Mon, 31 Oct 2016 23:17:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7abd2efa-99ba-4bd5-a117-ec8dd8d68208</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Instead of sd_power_system_off,  can you write directly as NRF_POWER-&amp;gt;SYSTEMOFF = 1;
Not sure if the name is correct.  It&amp;#39;s  midnight here and I&amp;#39;m half awake :)
You need to enable softdevice to use its API sd_xxx&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66472?ContentTypeID=1</link><pubDate>Mon, 31 Oct 2016 22:52:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6ae5aa82-b36c-4ee1-a832-bc2104aa297b</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;Just as a check, I have been trying to run code on the PCA10028 board.  Running the systemoff example with no soft device, I get low current consumption.  However, running the ble_app_beacon example, I cannot get the current below 1 mA.  The code is configured for an external crystal.  I have modified main.c so that it consists entirely of a single &amp;quot;sd_power_system_off();&amp;quot; call.  Here is all of main.c:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#include &amp;lt;stdbool.h&amp;gt;
#include &amp;lt;stdint.h&amp;gt;
//#include &amp;quot;ble_advdata.h&amp;quot;
#include &amp;quot;nordic_common.h&amp;quot;
#include &amp;quot;softdevice_handler.h&amp;quot;
#include &amp;quot;bsp.h&amp;quot;
//#include &amp;quot;app_timer.h&amp;quot;

int main(void)
{
  sd_power_system_off();  // enter systemoff 
  for (;; )
  {
  }
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I have restarted the chip to get out of debug mode, I am using the PCA10028 board, I am not using the GPIOTE module.  Am I missing a setting somewhere?
Thanks!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66475?ContentTypeID=1</link><pubDate>Sat, 29 Oct 2016 11:07:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5f8e3f03-788b-4216-8ca3-22a8580001a4</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;you can edit you question and then you can see the attachment options there. There is no attachment option for comments.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66471?ContentTypeID=1</link><pubDate>Fri, 28 Oct 2016 22:32:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6db8960d-1920-496e-9c43-c8c11207115d</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;It is not in debug mode (I have been careful to remove the debug cable and restart).  I have tried removing hardware dependent function calls and running on the dev board too, and it actually draws 3.5 mA there.  How can I send you the code?  I found the message function, but there does not seem to be a way to attach anything?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66470?ContentTypeID=1</link><pubDate>Fri, 28 Oct 2016 06:53:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b16849a6-b6a6-477a-a7a6-acb478dd2c6c</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;are you measuring this when the chip is in debug mode? i mean when your debugger is enabled. Then the CPU is not sleeping and drawing the current. I want to reproduce it here, can you please attach the project so that i can quickly test and give you a proper answer.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66469?ContentTypeID=1</link><pubDate>Thu, 27 Oct 2016 22:58:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8646acaf-2d35-456a-890f-5e3876bcad4a</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;I looked at the SWDIO/SWDCLK lines, and they are clean.  I though I read they have internal pull up/down?&lt;br /&gt;
I manually stopped the application timers before the systemoff statement, and now the systemoff recovers normally (good system restart), but the chip is drawing 2.5 mA (it was ~90 uA before).  I have tried setting all the pins every combination of input/output pull high/low (and also disconnected), but that didn&amp;#39;t reduce current consumption.  Any thoughts?  Is there anything else I need to shutdown manually before systemoff?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66468?ContentTypeID=1</link><pubDate>Thu, 27 Oct 2016 16:04:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:75395b6b-83e1-4b09-b3a5-5fab2595ff8a</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;are you using a custom board? seems like your device is going to debug mode due to some glitches on SWDIO/SWDCLK line. the while loop should never effect in non debug mode. check you have proper pull registers on those lines.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66467?ContentTypeID=1</link><pubDate>Thu, 27 Oct 2016 14:51:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cd3ec32d-5a30-4205-a810-1c38af544c1e</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;Here is the code surrounding the systemoff:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;NRF_POWER-&amp;gt;SYSTEMOFF = 1;   
//sd_nvic_SystemReset();
while(true)
{
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If I have the infinite loop, it never seems to restart normally.  If I uncomment the &amp;quot;sd_nvic_SystemReset();&amp;quot;, it resets on wakeup on about 1 out of 10 tries.&lt;br /&gt;
I am toggling pins and trying RTT print statements in my initialization code to see if anything is executing after the reset, but I don&amp;#39;t see any printing or pin-changing, and the chip never gets into its main loop.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66466?ContentTypeID=1</link><pubDate>Thu, 27 Oct 2016 09:31:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:88d32d3c-def0-4fdd-93c5-4733f85c1d37</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;after the system off do you have and infinite loop? that is needed in case if the system is in debug mode.&lt;/p&gt;
&lt;p&gt;can you please show me code of how you call system off&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66465?ContentTypeID=1</link><pubDate>Wed, 26 Oct 2016 14:32:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e5609c68-346b-4192-8521-216b3f611ec5</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;The input VDD is 3.3 V from an LDO that seems to be functioning well (we haven&amp;#39;t seen any problems with it).  The wakeup signal is the output from a Hall effect sensor IC (setup to act as a digital switch).  Its rise time is &amp;lt;2ms.&lt;/p&gt;
&lt;p&gt;Is there anything I could be doing with configurations, or peripherals, or the soft-device that would prevent a successful restart?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66464?ContentTypeID=1</link><pubDate>Wed, 26 Oct 2016 06:49:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f13126f-16f6-4fb0-aa3e-526a195becba</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Have not heard of this before, what is the wakeup source? and what is the input voltage you are using? Can you check if the voltage rise time is within the spec? It must rise vrom 0 to VDD within 100ms according to product specification Chapter 7 Table 20.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66463?ContentTypeID=1</link><pubDate>Tue, 25 Oct 2016 19:07:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2a115cc2-60a4-4aa5-95da-2bfe883a0452</guid><dc:creator>Dave_Avatech</dc:creator><description>&lt;p&gt;Thanks!  Is there anything I need to do to allow for normal operation after the chip reset?  The chip is booting up into some sort of frozen, unresponsive state.  It is also drawing nearly 6 mA.&lt;/p&gt;
&lt;p&gt;If I reset the chip using &amp;quot;sd_nvic_SystemReset();&amp;quot; it resets normally, but when I try to wakeup from systemoff, the chip always locks up.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: waking from sleep</title><link>https://devzone.nordicsemi.com/thread/66462?ContentTypeID=1</link><pubDate>Tue, 25 Oct 2016 07:30:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:077ef930-df6c-479c-b1f5-dd3a8e77b522</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Any wakeup from systemoff mode will automatically cause a chip reset. So your in_pin_handler will not be called. It will be called if you use WFE or WFI or sd_app_evt_wait instead of systemoff.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>