<?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>time keeping during sleep</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/25057/time-keeping-during-sleep</link><description>Hello experts, 
 I am getting into the word of Nordic and hence here is my first question. Kindly help. 
 Software version: SDK-14 
Hardware revision: nRF52832 DK (PCA10040) 
 I am using BLE_CENTRAL mode on nRF52832 and it works great out of the box</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 12 Sep 2017 08:33:30 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/25057/time-keeping-during-sleep" /><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98675?ContentTypeID=1</link><pubDate>Tue, 12 Sep 2017 08:33:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c075623b-652b-4217-9257-ff4ee6e90cff</guid><dc:creator>endnode</dc:creator><description>&lt;p&gt;If you want to scan it can be done only as periodic activity;) That&amp;#39;s how BLE works, there is no magic which would wake you up once some 2.4GHz photons hit your antenna... in addition while CPU is in SLEEP any HW peripheral can continue in autonomous operation so you can run RTC and simply check counter once you wake-up. There are examples of all the basics in nRF5 SDK, I&amp;#39;d say spend few weeks with it to get familiar and then most of things will be clear.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98670?ContentTypeID=1</link><pubDate>Tue, 12 Sep 2017 08:28:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c361e55a-ba69-4f25-a69f-2040e4ab5de9</guid><dc:creator>endnode</dc:creator><description>&lt;p&gt;That depends on what scheduled operations you started! If you don&amp;#39;t start any then nRF5x should stay in SLEEP until the end of the universe (or until your coin cell battery discharges, whatever happens first).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98671?ContentTypeID=1</link><pubDate>Tue, 12 Sep 2017 04:55:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:411f03d6-5894-40df-a3b1-0f3549fb5e97</guid><dc:creator>rk</dc:creator><description>&lt;p&gt;Ideally, I would like to achieve lowest possible power numbers on sleep since my device is battery operated. I would like to have this with coin cell battery for months at least :)&lt;/p&gt;
&lt;p&gt;However, as you stated that timekeeping is not possible with sysstem OFF mode, I would like to avoid system OFF mode.&lt;/p&gt;
&lt;p&gt;But, in system ON mode sleep, how do I avoid periodic wakeup of nRF. (I oberved wakeup for almost every 1ms).  I want to wakup only on EXTERNAL EVENT such as power button press on LE scan event etc.
kindly suggest&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98674?ContentTypeID=1</link><pubDate>Tue, 12 Sep 2017 04:51:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:442099fb-6b7b-46d2-8015-1f8ee4b2fb0a</guid><dc:creator>rk</dc:creator><description>&lt;p&gt;Thanks for the answers.&lt;/p&gt;
&lt;p&gt;But, as I am using nRF52x as Central, I would like to wake up only on receiving scan packet.(I don&amp;#39;t need periodic wake up) or wakeup  on Button press events&lt;/p&gt;
&lt;p&gt;But, once I wake up from sleep, I need to know what is the sleep duration (say 1 minues/10 minutes/1hr etc).&lt;/p&gt;
&lt;p&gt;May be this should be separate question/post. I have noticed that nRF52x wake-ups periodically with active sleep or power management provided in SDK14&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98672?ContentTypeID=1</link><pubDate>Mon, 11 Sep 2017 12:22:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c25aed0a-05d5-4520-81c6-613e0e72c1a4</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;If you are talking about System &lt;strong&gt;OFF&lt;/strong&gt; sleep mode, then the RTC and TIMER are turned off when you enter System OFF mode, and the nRF5x wont be able to keep track of time in this mode. See endnode&amp;#39;s answer in this &lt;a href="https://devzone.nordicsemi.com/question/167495/rtc-wake-up-not-happening-in-system-off-mode/?answer=167497#post-id-167497"&gt;thread&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;What power requirements are you looking for in the sleep mode?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: time keeping during sleep</title><link>https://devzone.nordicsemi.com/thread/98673?ContentTypeID=1</link><pubDate>Mon, 11 Sep 2017 08:23:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e475af62-551c-4807-a5f2-85401137d47c</guid><dc:creator>endnode</dc:creator><description>&lt;p&gt;No one would recommend external RTC component unless you want to get time triggers when nRF5x chip is in SYSTEM OFF mode. In normal operation (when it switches between normal operation of MCU and SYSTEM ON SLEEP when it waits for event/interrupt) you can use internal RTC for basic time keeping and periodical wake-ups. Most people use &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v14.0.0/lib_timer.html?cp=4_0_0_3_43"&gt;&lt;code&gt;app_timer&lt;/code&gt; library (see SDK examples)&lt;/a&gt; but indeed you can write simpler custom &amp;quot;library&amp;quot; if you need/want.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>