<?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>Setting advertisement parameter&amp;#39;s for custom profile</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/760/setting-advertisement-parameter-s-for-custom-profile</link><description>Hi,
How to set the advertisement parameter&amp;#39;s (uuid&amp;#39;s list) , while using both custom and SIG adopted services? 
 I modified the source code as below, but it is not showing the advertising data parameters and scan response data parameters while advertising</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 29 Oct 2013 10:27:26 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/760/setting-advertisement-parameter-s-for-custom-profile" /><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3844?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 10:27:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a1afbd6-f3a0-4a99-af0e-57d39e24016f</guid><dc:creator>balaji</dc:creator><description>&lt;p&gt;Thanks a lot Morten, i got the point. Since, i was calling the services_init(); after advertising_init(); i couldn&amp;#39;t able to get the value for m_accel.uuid_type, and the error value i got is 0x00000007. Thank you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3843?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 10:16:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb2cf87d-ad95-42a8-87ad-6470d947bb63</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;... which is exactly why you should have it there, catch the error and make sure you understand it, fix the cause of it, and then see everything working as it&amp;#39;s supposed to.&lt;/p&gt;
&lt;p&gt;Also, as I&amp;#39;ve told you before, you should remove the reset from app_error_handler, and use the debug_assert_handler, so that you can easily catch such errors.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3842?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 09:35:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:055ee566-2edd-4e21-9cb8-8048843729d2</guid><dc:creator>balaji</dc:creator><description>&lt;p&gt;I tried with  APP_ERROR_CHECK(err_code); now my device is not advertising.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3841?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 09:31:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f365c17f-a97e-4656-ada8-de348ddcc232</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;You don&amp;#39;t check the error code returned by ble_advdata_set(). You should ALWAYS check error codes!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3840?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 09:29:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d759d4c1-cee3-42f4-8167-c7cea5dc0bfb</guid><dc:creator>balaji</dc:creator><description>&lt;p&gt;I tried as you said, but in MCP, i couldn&amp;#39;t see any values below the Advertising Data, and Scan Response Data.
I attached the image of my MCP, and also edited the above post with my code.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Setting advertisement parameter's for custom profile</title><link>https://devzone.nordicsemi.com/thread/3839?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 10:11:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:77d2c898-ad44-417c-859d-22c0b3fe88e2</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;There shouldn&amp;#39;t be any particular problems with this, and it can be done for example as follows (modified from the &lt;a href="https://www.nordicsemi.com/eng/content/download/34055/573345/file/nAN-36.zip"&gt;nAN-36&lt;/a&gt; code):&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;
    ble_uuid_t adv_uuids[] = {{LBS_UUID_SERVICE, m_lbs.uuid_type},
                              {BLE_UUID_HEART_RATE_SERVICE, BLE_UUID_TYPE_BLE}};

    // Build and set advertising data
    memset(&amp;amp;advdata, 0, sizeof(advdata));
    advdata.name_type               = BLE_ADVDATA_FULL_NAME;
    advdata.include_appearance      = true;
    advdata.flags.size              = sizeof(flags);
    advdata.flags.p_data            = &amp;amp;flags;
    
    memset(&amp;amp;scanrsp, 0, sizeof(scanrsp));
    scanrsp.uuids_complete.uuid_cnt = sizeof(adv_uuids) / sizeof(adv_uuids[0]);
    scanrsp.uuids_complete.p_uuids  = adv_uuids;
    
    err_code = ble_advdata_set(&amp;amp;advdata, &amp;amp;scanrsp);
    APP_ERROR_CHECK(err_code);

&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Edit: Your added code snippet does not check the error code of ble_advdata_set(), and based on your screenshots, it&amp;#39;s pretty likely that advdata_set() returned an error and didn&amp;#39;t do anything. You should &lt;em&gt;always&lt;/em&gt; check error codes!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>