<?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>Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/85044/advertising-init-as-nonconnectable-but-still-shows-as-connectable</link><description>I can not seem to figure out why when I init the advertising and then issue a start to the advertising the advertising beacon shows up as a connectable when viewing under nRFConnect app. 
 I have put the defines, and the two functions that I am using</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 02 Mar 2022 17:49:29 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/85044/advertising-init-as-nonconnectable-but-still-shows-as-connectable" /><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/355904?ContentTypeID=1</link><pubDate>Wed, 02 Mar 2022 17:49:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dba777c1-3dc8-46de-a64d-36bc2d2f2373</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;Thank you for the information.&amp;nbsp; All of it is working very well right now.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/355788?ContentTypeID=1</link><pubDate>Wed, 02 Mar 2022 11:30:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ef7ba630-3ca2-4419-8a73-7912eefc9556</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Good to hear that it works now. Note that the 32 KHz crystal will give you a slightly lower average current if you have the option to choose.&lt;/p&gt;
[quote user="AllenS"]1. Is the internal DCDC regulator enabled by default?[/quote]
&lt;p&gt;We use the LDO by default, but you can call &lt;span&gt;&lt;a title="sd_power_dcdc_mode_set" href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.3.0/group___n_r_f___s_o_c___f_u_n_c_t_i_o_n_s.html?cp=4_7_3_1_2_7_2_13#ga84bd6a0e8f55a7aa85a5ec608edd61fe"&gt;sd_power_dcdc_mode_set&lt;/a&gt;&lt;/span&gt;(&lt;em&gt;NRF_POWER_DCDC_ENABLE&lt;/em&gt;&amp;nbsp;) after ble_stack_init() to enable it.&amp;nbsp; However, before you enabling it, please make sure you have the DCDC inductors included in your design:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1646219977227v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;Otherwise, you may risk bricking the device.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;2. Idle and system ON is the same in this context. I.e. the device enters System ON when you call the idle function from your main loop.&lt;/p&gt;
[quote user="AllenS"]Does the profiler take into consideration the other passives on the board that allow the micro to function?[/quote]
&lt;p&gt;Yes, the power profiler data is based on actual measurements.&lt;/p&gt;
&lt;p&gt;3. &lt;span&gt;&lt;a title="sd_ble_gap_tx_power_set" href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v7.3.0/group___b_l_e___g_a_p___f_u_n_c_t_i_o_n_s.html?cp=4_7_3_1_2_1_3_41#gad10e80ba20ddab42d1753fd1be2d8c26"&gt;sd_ble_gap_tx_power_set&lt;/a&gt;&lt;/span&gt;(&lt;em&gt;BLE_GAP_TX_POWER_ROLE_ADV&lt;/em&gt; , 0, &amp;lt;tx power&amp;gt;).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/355668?ContentTypeID=1</link><pubDate>Tue, 01 Mar 2022 23:45:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:55499bc5-26c1-4c07-961c-927712efbca5</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;Adding static as you suggested fixed the beacon data issue.&amp;nbsp; I found the NRF_SDH_CLOCK_LF_SRC symbol and changed it as you suggested and verified operation still worked after disabling the 32KHz crystal.&amp;nbsp; So now, I am back on track again.&amp;nbsp; So I have a few more questions if you do not mind.&lt;/p&gt;
&lt;p&gt;1. Is the internal DCDC regulator enabled by default?&lt;/p&gt;
&lt;p&gt;2. When I ran the online power profiler and plugged in the variables for my application, I liked the result that it came back with.&amp;nbsp; Does the profiler take into consideration not really going into sleep (System On) but rather Idle as in the case of the beacon app example?&amp;nbsp; Does the profiler take into consideration the other passives on the board that allow the micro to function?&lt;/p&gt;
&lt;p&gt;3. Can you point me where I need to go to adjust the TX Power output of the beacon?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354959?ContentTypeID=1</link><pubDate>Fri, 25 Feb 2022 09:11:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:464ac182-9f56-439b-94a9-9e7d0c438cb9</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;I don&amp;#39;t see why initializing the m_enc_advdata buffers would make any difference. Anyway, I see now that I had not placed the manuf_specific_data variable in static memory. So the p_manuf_specific_data ends up pointing to a stack variable.&lt;/p&gt;
&lt;p&gt;Please try to define this variable as &amp;#39;static&amp;#39; and see if fixes the problem:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt; static ble_advdata_manuf_data_t manuf_specific_data;&lt;/pre&gt;&lt;/p&gt;
[quote userid="111673" url="~/f/nordic-q-a/85044/advertising-init-as-nonconnectable-but-still-shows-as-connectable/354888#354888"]Would it not be better to take care of all the housekeeping in one event rather than multiple events firing asynchronously?[/quote]
&lt;p&gt;In theory yes, but I doubt it will make a noticeable difference in practice. The time it takes to wake up to service an interrupt is only a few micro seconds. What&amp;#39;s more important is how often you decide to read the voltage. It does not make sense to sample a battery voltage every 5 seconds if the battery is expected to last for several months. &lt;/p&gt;
[quote userid="111673" url="~/f/nordic-q-a/85044/advertising-init-as-nonconnectable-but-still-shows-as-connectable/354888#354888"]As for the 32KHz source, where do I go check to see if the external crystal is enabled or does it just default to the internal 32KHz source by default?[/quote]
&lt;p&gt;You can see which clock source the Softdevice the will be configured with from the NRF_SDH_CLOCK_LF_SRC symbol in sdk_config.h. Our SDK BLE examples have the LF crystal selected by default.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354904?ContentTypeID=1</link><pubDate>Fri, 25 Feb 2022 00:51:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:de6a9d4e-73c3-4797-afed-4f691a174a26</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;UPDATE:&amp;nbsp; I started investigating what could have caused a difference between the advertising_init and the subsequent update routine.&amp;nbsp; The only thing I could come up with had to do with initializing both encode buffers in the advertising_init routine.&amp;nbsp; That did take care of the ERROR 12 issue.&amp;nbsp; However, when you go look at the nRF Connect app to see the beacon data, something somewhere is becoming corrupted and not pointing to the correct data.&amp;nbsp; Below is the code snippet for the advertising_init:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt; uint32_t      err_code;

 NRF_LOG_INFO(&amp;quot;advertising_init&amp;quot;);

// ble_advdata_t advdata;  // moved to a global position

 // flags must be this for beacon to work properly
 uint8_t       flags = BLE_GAP_ADV_FLAG_BR_EDR_NOT_SUPPORTED;

 // Changing to this flag causes an ERROR 7 to occur if m_adv_params.duration = 0
 //   Even if you change the duration to 5 you still see nothing on nRF Connect App
 //uint8_t       flags = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;

 ble_advdata_manuf_data_t manuf_specific_data;

 manuf_specific_data.company_identifier = APP_COMPANY_IDENTIFIER;

 manuf_specific_data.data.p_data = (uint8_t *) m_beacon_info;
 manuf_specific_data.data.size   = APP_BEACON_INFO_LENGTH;

 // Build and set advertising data.
 memset(&amp;amp;advdata, 0, sizeof(advdata));

 advdata.name_type             = BLE_ADVDATA_NO_NAME;
// advdata.name_type             = BLE_ADVDATA_FULL_NAME;
 advdata.flags                 = flags;
 advdata.p_manuf_specific_data = &amp;amp;manuf_specific_data;

 // Initialize advertising parameters (used when starting advertising).
 memset(&amp;amp;m_adv_params, 0, sizeof(m_adv_params));

 m_adv_params.properties.type = BLE_GAP_ADV_TYPE_NONCONNECTABLE_NONSCANNABLE_UNDIRECTED;
 m_adv_params.p_peer_addr     = NULL;    // Undirected advertisement.
 m_adv_params.filter_policy   = BLE_GAP_ADV_FP_ANY;
 m_adv_params.interval        = NON_CONNECTABLE_ADV_INTERVAL;
 m_adv_params.duration        = 0;  // Never time out.  Must be zero for beacon to work properly

 m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[1][0];

 NRF_LOG_INFO(&amp;quot;adv_init enc buf 1&amp;quot;);

 err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len); 
 APP_ERROR_CHECK(err_code);

 NRF_LOG_HEXDUMP_INFO(m_adv_data.adv_data.p_data, m_adv_data.adv_data.len);

 NRF_LOG_INFO(&amp;quot;adv_init enc buf 0&amp;quot;);

 m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[0][0];

 err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);
 APP_ERROR_CHECK(err_code);

 NRF_LOG_HEXDUMP_INFO(m_adv_data.adv_data.p_data, m_adv_data.adv_data.len);

 err_code = sd_ble_gap_adv_set_configure(&amp;amp;m_adv_handle, &amp;amp;m_adv_data, &amp;amp;m_adv_params);
 APP_ERROR_CHECK(err_code);&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Below is the updated code for the update routine:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;
   uint32_t err_code;
   uint8_t loc_index = BATT_VAL_OFFSET_IN_BEACON_INFO;

   NRF_LOG_INFO(&amp;quot;Adv data update started.&amp;quot;);

   /* This is an [in][out] variable used by the encode function */
   m_adv_data.adv_data.len = BLE_GAP_ADV_SET_DATA_SIZE_MAX;

   m_beacon_info[loc_index] = app_Batt_PCnt; // Batt percent value

   /* Swap adv data buffer - from API doc: &amp;quot;In order to update advertising
      data while advertising,new advertising buffers must be provided&amp;quot; */

   if (f_enc_idx &amp;amp; 1)
     {
      m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[0][0];
     }
   else
     {
      m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[1][0];
     }

   ++f_enc_idx;

   /* Go encode the updated beacon data for the buffer that was selected */
   err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);
   APP_ERROR_CHECK(err_code);

//   NRF_LOG_HEXDUMP_INFO(m_adv_data.adv_data.p_data, m_adv_data.adv_data.len);

   err_code = sd_ble_gap_adv_set_configure(&amp;amp;m_adv_handle, &amp;amp;m_adv_data, NULL);
   APP_ERROR_CHECK(err_code);

   NRF_LOG_INFO(&amp;quot;Advertising payload updated.&amp;quot;);
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;This is what I see when I capture on the debug terminal:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;
&amp;lt;info&amp;gt; app_timer: RTC: initialized.

&amp;lt;info&amp;gt; app: advertising_init

&amp;lt;info&amp;gt; app: adv_init enc buf 1

&amp;lt;info&amp;gt; app:  02 01 04 1A FF 59 00 02|.....Y..

&amp;lt;info&amp;gt; app:  15 01 12 23 34 45 56 67|...#4EVg

&amp;lt;info&amp;gt; app:  78 89 9A AB BC CD DE EF|x.......

&amp;lt;info&amp;gt; app:  F0 00 00 80 C3 50      |.....P  

&amp;lt;info&amp;gt; app: adv_init enc buf 0

&amp;lt;info&amp;gt; app:  02 01 04 1A FF 59 00 02|.....Y..

&amp;lt;info&amp;gt; app:  15 01 12 23 34 45 56 67|...#4EVg

&amp;lt;info&amp;gt; app:  78 89 9A AB BC CD DE EF|x.......

&amp;lt;info&amp;gt; app:  F0 00 00 80 C3 50      |.....P  

&amp;lt;info&amp;gt; app: Beacon example started.

&amp;lt;info&amp;gt; app: advertising_start

04:04:12.910: &amp;lt;info&amp;gt; app: Adv data update started.

&amp;lt;info&amp;gt; app: Advertising payload updated.

04:04:17.976: &amp;lt;info&amp;gt; app: Adv data update started.

&amp;lt;info&amp;gt; app: Advertising payload updated.

04:04:22.901: &amp;lt;info&amp;gt; app: Adv data update started.

&amp;lt;info&amp;gt; app: Advertising payload updated.

04:04:27.961: &amp;lt;info&amp;gt; app: Adv data update started.

&amp;lt;info&amp;gt; app: Advertising payload updated.

04:04:32.990: &amp;lt;info&amp;gt; app: Adv data update started.

&amp;lt;info&amp;gt; app: Advertising payload updated.

&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;On the nRF Connect app the raw data I see is:&lt;/p&gt;
&lt;p&gt;0x02010403FF0000&lt;/p&gt;
&lt;p&gt;If I back out the update routine, everything seems to work fine with no updates.&amp;nbsp; Any ideas?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354902?ContentTypeID=1</link><pubDate>Thu, 24 Feb 2022 22:52:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:87c05332-8b21-41d5-863b-75e3a2daee60</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;I implemented the async timed advertise update function and have run into two issues.&lt;/p&gt;
&lt;p&gt;1. On the first update attempt the nRF Log dumps out and ERROR 12&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app_timer: RTC: initialized.&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: advertising_init&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: Beacon example started.&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: advertising_start&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: Adv data update started.&lt;/p&gt;
&lt;p&gt;&amp;lt;error&amp;gt; app: ERROR 12 [NRF_ERROR_DATA_SIZE]&lt;/p&gt;
&lt;p&gt;on this line of code:&lt;/p&gt;
&lt;p&gt;err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);&lt;/p&gt;
&lt;p&gt;The only things that changed were the one uint8_t data in the beacon that represents the battery percentage and further in the code which encode buffer to point to when the encode function is called.&amp;nbsp; Below is the code from the handler:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;
   uint32_t err_code;
   uint8_t loc_index = BATT_VAL_OFFSET_IN_BEACON_INFO;

   NRF_LOG_INFO(&amp;quot;Adv data update started.&amp;quot;);

   /* This is an [in][out] variable used by the encode function */
   m_adv_data.adv_data.len = BLE_GAP_ADV_SET_DATA_SIZE_MAX;

   m_beacon_info[loc_index] = app_Batt_PCnt; // Batt percent value

   /* Swap adv data buffer - from API doc: &amp;quot;In order to update advertising
      data while advertising,new advertising buffers must be provided&amp;quot; */

   if (f_enc_idx &amp;amp; 1)
     {
      m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[0][0];
     }
   else
     {
      m_adv_data.adv_data.p_data = &amp;amp;m_enc_advdata[1][0];
     }

   ++f_enc_idx;

   /* Go encode the updated beacon data for the buffer that was selected */
   err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);
   APP_ERROR_CHECK(err_code);

   err_code = sd_ble_gap_adv_set_configure(&amp;amp;m_adv_handle, &amp;amp;m_adv_data, NULL);
   APP_ERROR_CHECK(err_code);

   NRF_LOG_INFO(&amp;quot;Advertising payload updated.&amp;quot;);
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;The advertising_init code initializes the structures and calls the same encode function and does not seem to have a problem with the data sizes.&amp;nbsp; See the code snippet below:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;
// ble_advdata_t advdata;  // moved to a global position

 // flags must be this for beacon to work properly
 uint8_t       flags = BLE_GAP_ADV_FLAG_BR_EDR_NOT_SUPPORTED;

 // Changing to this flag causes an ERROR 7 to occur if m_adv_params.duration = 0
 //   Even if you change the duration to 5 you still see nothing on nRF Connect App
 //uint8_t       flags = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;

 ble_advdata_manuf_data_t manuf_specific_data;

 manuf_specific_data.company_identifier = APP_COMPANY_IDENTIFIER;

 manuf_specific_data.data.p_data = (uint8_t *) m_beacon_info;
 manuf_specific_data.data.size   = APP_BEACON_INFO_LENGTH;

 // Build and set advertising data.
 memset(&amp;amp;advdata, 0, sizeof(advdata));

 advdata.name_type             = BLE_ADVDATA_NO_NAME;
// advdata.name_type             = BLE_ADVDATA_FULL_NAME;
 advdata.flags                 = flags;
 advdata.p_manuf_specific_data = &amp;amp;manuf_specific_data;

 // Initialize advertising parameters (used when starting advertising).
 memset(&amp;amp;m_adv_params, 0, sizeof(m_adv_params));

 m_adv_params.properties.type = BLE_GAP_ADV_TYPE_NONCONNECTABLE_NONSCANNABLE_UNDIRECTED;
 m_adv_params.p_peer_addr     = NULL;    // Undirected advertisement.
 m_adv_params.filter_policy   = BLE_GAP_ADV_FP_ANY;
 m_adv_params.interval        = NON_CONNECTABLE_ADV_INTERVAL;
 m_adv_params.duration        = 0;  // Never time out.  Must be zero for beacon to work properly

 err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);
 APP_ERROR_CHECK(err_code);

 err_code = sd_ble_gap_adv_set_configure(&amp;amp;m_adv_handle, &amp;amp;m_adv_data, &amp;amp;m_adv_params);
 APP_ERROR_CHECK(err_code);
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;2. When trying to actually debug the code I run into this error:&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app_timer: RTC: initialized.&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: advertising_init&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: Beacon example started.&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: advertising_start&lt;/p&gt;
&lt;p&gt;&amp;lt;info&amp;gt; app: Adv data update started.&lt;/p&gt;
&lt;p&gt;&amp;lt;error&amp;gt; app: SOFTDEVICE: ASSERTION FAILED&lt;/p&gt;
&lt;p&gt;It just so happens inside of the advertising update function on line:&lt;/p&gt;
&lt;p&gt;err_code = ble_advdata_encode(&amp;amp;advdata, m_adv_data.adv_data.p_data, &amp;amp;m_adv_data.adv_data.len);&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Any ideas on how to get past both these issues?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354888?ContentTypeID=1</link><pubDate>Thu, 24 Feb 2022 20:15:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:df542e33-249e-4b35-a330-7fa840a7d296</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;It is not important to have the data updated exactly before the advertisement event.&amp;nbsp; It just needs to be updated at some point in time.&amp;nbsp; My thoughts were if I am going to be active then be active for all things before going back to idle for a long period of time.&amp;nbsp; Otherwise, I may be active for the beacon advertise and then later become active for an A2D sample.&amp;nbsp; Would it not be better to take care of all the housekeeping in one event rather than multiple events firing asynchronously?&lt;/p&gt;
&lt;p&gt;As for the 32KHz source, where do I go check to see if the external crystal is enabled or does it just default to the internal 32KHz source by default?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354883?ContentTypeID=1</link><pubDate>Thu, 24 Feb 2022 18:48:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:558b3c04-3b6c-4a9b-8336-12fa36ffec18</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;1. It uses the 32 KHz source. Unlike the 32 MHz, this clock is always active while the Softdevice is enabled, so it does not affect the power consumption.&lt;/p&gt;
&lt;p&gt;2. The app_timer uses RTC1 which has a run current of only ~0.1 uA.&lt;/p&gt;
&lt;p&gt;3. You could configure the app timer instance run in APP_TIMER_MODE_SINGLE_SHOT mode, then start it every time you get the nACTIVE signal from the Softdevice. But how important is it to have the data updated exactly before the advertisment event? Observers will not usually be able to receive all advertisement packets anyway.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354881?ContentTypeID=1</link><pubDate>Thu, 24 Feb 2022 18:18:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ce691c35-3738-44de-84fa-e75ceb8097fa</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;I noticed in your advertise-battery-level-in-beacon-advertising-packet link above you provide an attachment zip example.&amp;nbsp; I do see in that example you generate an asynchronous timer for updating the beacon data.&amp;nbsp; That leads me to a few questions regarding this.&lt;/p&gt;
&lt;p&gt;1. Is the async timer based on the 32 MHz crystal input or the 32 KHz clock?&lt;/p&gt;
&lt;p&gt;2. Regardless of which clock source the async timer is running on, how can I determine through the online power profiler if additional current consumption is being used by this timer since it would be asynchronous?&lt;/p&gt;
&lt;p&gt;3. How would you go about syncing to the advertisement start?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354741?ContentTypeID=1</link><pubDate>Thu, 24 Feb 2022 09:06:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:53d0afa6-02bd-48fa-985a-0485ae8491ab</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;I would expect there to be enough time to perform a single A2D reading and processing between the ACTIVE signal and the advertising start event. I think it mainly depends on how long time the A2D sampling takes as there isn&amp;#39;t much CPU processing involved in updating the payload.&lt;/p&gt;
&lt;p&gt;Otherwise, you will have to use a timer instance like in my example and try to synchronize it to the advertisement start. &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354695?ContentTypeID=1</link><pubDate>Wed, 23 Feb 2022 23:02:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5ae9f739-2d38-44f5-896e-b8c9711dfc80</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;I am finding out that using the beacon app example is providing me the closest solution to the project I am working on.&amp;nbsp; As you stated before, the advertising.c is really for connectable advertising and working directly with the soft device is better for the non-connectable solution.&amp;nbsp; So I have shelved the advertising.c for now and have been looking at the link you sent and have been experimenting with some of the things presented in there.&amp;nbsp; I do think the Radio Notification Signals is a good approach to a pre-transmission event.&amp;nbsp; Do you think there would be enough time to take a single A2D reading, process it, update a single byte in the advertising beacon data and then go into a Sleep/Idle mode for power conservation until the next time the advertising is set to occur?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354680?ContentTypeID=1</link><pubDate>Wed, 23 Feb 2022 17:59:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1853f260-e55c-45f2-a339-3b59e709073c</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Sorry, I did not notice that you were using the advertising module and just assumed you were working directly with the Softdevice APIs like how it&amp;#39;s done in the original beacon example. As you have noticed, the problem with the advertising module is expose any options to select non-connectable advertising.&lt;/p&gt;
&lt;p&gt;I made a small demo showing how you can update the beacon data a while ago which I posted here: &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/78948/advertise-battery-level-in-beacon-advertising-packet/326766#326766"&gt;https://devzone.nordicsemi.com/f/nordic-q-a/78948/advertise-battery-level-in-beacon-advertising-packet/326766#326766&lt;/a&gt;. Is that something you can use? I used a timer interrupt to update the adv. payload in that example, but you can also use &lt;span&gt;&lt;a title="Radio Notification signals" href="https://infocenter.nordicsemi.com/topic/sds_s132/SDS/s1xx/radio_notif/radio_notif.html?cp=4_7_3_0_10_0"&gt;Radio Notification signals&lt;/a&gt;&lt;/span&gt; for the same if you want the update to be synchronized to the adv. events.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354671?ContentTypeID=1</link><pubDate>Wed, 23 Feb 2022 16:17:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:95326aba-3ce7-49e0-8fb0-b33a4d88307b</guid><dc:creator>AllenS</dc:creator><description>&lt;p&gt;Hello Vidar,&lt;/p&gt;
&lt;p&gt;I am able to do the same of what you are describing.&amp;nbsp; However, that is not my issue.&amp;nbsp; My issue is about using the ble_advertising_init function and not being able to create an advertising beacon that is non-connectable.&amp;nbsp; After looking at the structures that are available using this function, I have noticed there is no&amp;nbsp;ble_gap_adv_params_t structure that is being initialized that allows for the setting of&amp;nbsp;properties.type = BLE_GAP_ADV_TYPE_NONCONNECTABLE_NONSCANNABLE_UNDIRECTED;&lt;/p&gt;
&lt;p&gt;The example of ble_beacon_app does allow for this property type to be set.&amp;nbsp; Therefore, when the example is run you get an advertising beacon with the data that is specified in&amp;nbsp;p_manuf_specific_data.&lt;/p&gt;
&lt;p&gt;So, with that in mind, how would one go about updating a few bytes of the&amp;nbsp;p_manuf_specific_data in the advertising beacon&amp;nbsp; prior to the advertising beacon being transmitted?&amp;nbsp; I have not found a way to specify an event handler to perform an update such as this in a non-connectable example.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising init as nonconnectable but still shows as connectable?</title><link>https://devzone.nordicsemi.com/thread/354598?ContentTypeID=1</link><pubDate>Wed, 23 Feb 2022 13:37:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2888a754-1ed8-4210-99ea-47661ecfcc34</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I was able to reproduce the same when I did the following:&lt;/p&gt;
&lt;p&gt;1. Flashed some FW that did connectable advertising&lt;/p&gt;
&lt;p&gt;2. Started scanning in the nRF connect app and saw that the device was shown as connectable.&lt;/p&gt;
&lt;p&gt;3. Re-programmed the board with the beacon example&lt;/p&gt;
&lt;p&gt;4. Observed that the device was still displayed as connectable.&lt;/p&gt;
&lt;p&gt;But the connect button disappeared after I pressed the &amp;quot;Refresh&amp;quot; button indicating that it&amp;#39;s a caching issue, either in the app or in the Android BT stack. Does the same work for you?&lt;/p&gt;
&lt;p&gt;Refresh button:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/Screenshot_5F00_20220223_2D00_143151.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Vidar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>