<?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>how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/11996/how-to-let-nrf51822-ble_app_uart-never-sleep</link><description>As title, im using nRF51822 as a ble uart.(ble_app_uart) 
 But it will sleep when No connect for some time. 
 how can i turn off the sleep mode? 
 I want it be a &amp;quot;always on BLE UART&amp;quot; and wait for connect. 
 
 
 
 i did this 
 for (;;)
{
 //power_manage</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 30 Sep 2016 13:17:54 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/11996/how-to-let-nrf51822-ble_app_uart-never-sleep" /><item><title>RE: how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/thread/45405?ContentTypeID=1</link><pubDate>Fri, 30 Sep 2016 13:17:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9cef6ff5-b604-428c-8f7d-3477c6aae2b5</guid><dc:creator>chtsai</dc:creator><description>&lt;p&gt;I has same problem and ask question:
What happen if APP_ADV_TIMEOUT_IN_SECONDS set to 0 , disable fast advertisement but still advertisement and not enter idle mode ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/thread/45407?ContentTypeID=1</link><pubDate>Tue, 23 Feb 2016 10:53:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:39fbffef-ee95-4cb0-bbcd-8e73073cc3a8</guid><dc:creator>ZhenYi</dc:creator><description>&lt;p&gt;This solution is so great!
Its helpful, thank you!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/thread/45404?ContentTypeID=1</link><pubDate>Tue, 23 Feb 2016 10:52:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:348e886f-9ee6-4be6-a296-ee22b619fee9</guid><dc:creator>ZhenYi</dc:creator><description>&lt;p&gt;I got the point I lost, thank you for this answer!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/thread/45406?ContentTypeID=1</link><pubDate>Mon, 22 Feb 2016 10:30:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:67316537-81b2-4d79-9963-b8651f99bad0</guid><dc:creator>Marco Russi</dc:creator><description>&lt;p&gt;Hi, you can restart advertising after timeout elapses by adding the related function call in BLE_ADV_EVT_IDLE case as below:&lt;/p&gt;
&lt;p&gt;case BLE_ADV_EVT_IDLE:
{
/* start advertising again */
ret_code_t err_code = ble_advertising_start(BLE_ADV_MODE_FAST);
APP_ERROR_CHECK(err_code);
}&lt;/p&gt;
&lt;p&gt;I hope this helps.
Thanks.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: how to let nRF51822 ble_app_uart never sleep?</title><link>https://devzone.nordicsemi.com/thread/45403?ContentTypeID=1</link><pubDate>Mon, 22 Feb 2016 08:13:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:47549b66-aa59-43ce-8ec1-e2810688cfae</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;This is not a issue of sleeping. The device will sleep between advertisements etc, but wake up whenever there is work to do.&lt;/p&gt;
&lt;p&gt;I suspect that the problem here is that the advertising timeout is set to 180 seconds. After that it will stop advertising, and not start advertising again until you press button 2 (generating an &lt;code&gt;BSP_EVENT_WHITELIST_OFF&lt;/code&gt; event). Note that the first 180 seconds the device will do fast advertising (using the whitelist), and other devices cannot connect until the button is clicked and &lt;code&gt;ble_advertising_restart_without_whitelist()&lt;/code&gt; is called. You can modify the type and duration of advertisements in the code to fit your need.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>