<?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>nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/66504/nrf52840-sdk16---passing-unique-id-deviceid-in-advertising-data</link><description>Hi everyone, 
 I want instead of MAC address to advertise my device using its 64bit unique ID. What I am considering, is to use the p_data array for that purpose and more specific to advertise using scan responce format as follows 
 
 My problem is that</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 09 Oct 2020 07:33:28 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/66504/nrf52840-sdk16---passing-unique-id-deviceid-in-advertising-data" /><item><title>RE: nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/thread/273933?ContentTypeID=1</link><pubDate>Fri, 09 Oct 2020 07:33:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c5987d0d-07d8-46ae-8951-e8252b7edaba</guid><dc:creator>Nikosant03</dc:creator><description>&lt;p&gt;Based on the&amp;nbsp;&lt;span&gt;ble_app_hids_mouse example I figured out how to implement it. Thanks a lot!!&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/thread/272870?ContentTypeID=1</link><pubDate>Mon, 05 Oct 2020 07:28:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7a428d98-a9c6-42a7-9716-cf6c05899564</guid><dc:creator>Nikosant03</dc:creator><description>&lt;p&gt;Thank you Kenneth,&lt;/p&gt;
&lt;p&gt;I will also try the softdevice API and will look the&amp;nbsp;&lt;span&gt;ble_app_hids_mouse example and will return with a feedback.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;In the meanwhile, can you spot any error with my advertising_init funciton that prevents from advertising scan responce data?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static void advertising_init(void) {
  
  ret_code_t err_code;
  ble_advertising_init_t init; // configuration structure
  uint8_t uniqueID[]={01,02,03};

  memset(&amp;amp;init, 0, sizeof(init));

  init.advdata.name_type = BLE_ADVDATA_FULL_NAME;
  init.advdata.include_appearance = false;

  init.advdata.flags = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;
  init.advdata.uuids_complete.uuid_cnt = 1;              
  init.advdata.uuids_complete.p_uuids = &amp;amp;m_adv_uuids[0];
  
  init.srdata.p_manuf_specific_data-&amp;gt;data.size = sizeof(uniqueID) / sizeof(uniqueID[0]);
  init.srdata.p_manuf_specific_data-&amp;gt;data.p_data = uniqueID;

  init.config.ble_adv_fast_enabled = true;
  init.config.ble_adv_fast_interval = APP_ADV_INTERVAL;
  init.config.ble_adv_fast_timeout = APP_ADV_DURATION;

  init.evt_handler = on_adv_evt;

  err_code = ble_advertising_init(&amp;amp;m_advertising, &amp;amp;init);
  APP_ERROR_CHECK(err_code);

  ble_advertising_conn_cfg_tag_set(&amp;amp;m_advertising, APP_BLE_CONN_CFG_TAG);
}&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/thread/272865?ContentTypeID=1</link><pubDate>Mon, 05 Oct 2020 06:55:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9329f7a2-737c-4270-ba1a-04683b761939</guid><dc:creator>Kenneth</dc:creator><description>[quote user="Nikosant03"]Could you provide me some clarifications?[/quote]
&lt;p&gt;You can choose either. It&amp;#39;s just two different engineers making each example. One is using a ble advertising module to setup the advertisement, while the other is using the softdevice api directly.&lt;/p&gt;
&lt;p&gt;If you open the ble_app_hids_mouse example you can for instance see how it is setting up manufacturer packet in the advertisement by searching for&amp;nbsp;SWIFT_PAIR_SUPPORTED in main.c&lt;/p&gt;
&lt;p&gt;Best regards,&lt;br /&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/thread/272651?ContentTypeID=1</link><pubDate>Fri, 02 Oct 2020 06:00:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:16d6cae8-babd-4bac-9106-65e334f54915</guid><dc:creator>Nikosant03</dc:creator><description>&lt;p&gt;Hi Kenneth and thank you for your responce,&lt;/p&gt;
&lt;p&gt;I&amp;#39;ve just saw the &lt;span&gt;\ble_app_blinky example&lt;/span&gt; and I realized that the structure of my advertising_init() function differs. However, is similar with the \ble_app_hrs example&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span&gt;The \ble_app_blinky example&lt;/span&gt; uses the&amp;nbsp;&lt;strong&gt;ble_advdata_encode&lt;/strong&gt; &amp;amp; &lt;strong&gt;sd_ble_gap_adv_set_configure&lt;/strong&gt; functions, while \&lt;span&gt;ble_app_hrs example uses the&amp;nbsp;&lt;strong&gt;ble_advertising_init&lt;/strong&gt; &amp;amp;&amp;nbsp;&lt;strong&gt;ble_advertising_conn_cfg_tag_set to setup the&amp;nbsp;advertising_init&amp;nbsp;&lt;/strong&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Could you provide me some clarifications?&lt;/p&gt;
&lt;p&gt;This is my&amp;nbsp;&lt;span&gt;advertising_init() function. Should I follow the blinky example?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;static void advertising_init(void) {
  
  ret_code_t err_code;
  ble_advertising_init_t init; // configuration structure
  uint8_t uniqueID[]={01,02,03};

  memset(&amp;amp;init, 0, sizeof(init));

  init.advdata.name_type = BLE_ADVDATA_FULL_NAME;
  init.advdata.include_appearance = false;

  init.advdata.flags = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;
  init.advdata.uuids_complete.uuid_cnt = 1;              
  init.advdata.uuids_complete.p_uuids = &amp;amp;m_adv_uuids[0];
  
  init.srdata.p_manuf_specific_data-&amp;gt;data.size = sizeof(uniqueID) / sizeof(uniqueID[0]);
  init.srdata.p_manuf_specific_data-&amp;gt;data.p_data = uniqueID;

  init.config.ble_adv_fast_enabled = true;
  init.config.ble_adv_fast_interval = APP_ADV_INTERVAL;
  init.config.ble_adv_fast_timeout = APP_ADV_DURATION;

  init.evt_handler = on_adv_evt;

  err_code = ble_advertising_init(&amp;amp;m_advertising, &amp;amp;init);
  APP_ERROR_CHECK(err_code);

  ble_advertising_conn_cfg_tag_set(&amp;amp;m_advertising, APP_BLE_CONN_CFG_TAG);
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Nick&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52840 SDK16 - Passing unique ID DEVICEID in advertising data</title><link>https://devzone.nordicsemi.com/thread/272471?ContentTypeID=1</link><pubDate>Thu, 01 Oct 2020 10:06:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ceb117d-d05d-49a4-9971-aa93ae16486a</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I don&amp;#39;t see any obvious errors from the short code snippet, are you getting any error code? Have you tried to do this change in for instance the \ble_app_blinky example which for instance are using scan response data?&lt;/p&gt;
&lt;p&gt;Also make sure that you set manuf_data.company_identifier before calling&amp;nbsp;ble_advdata_encode().&lt;/p&gt;
&lt;p&gt;Best regards,&lt;br /&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>