<?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>Problem with custom service UUID and Notify</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/8976/problem-with-custom-service-uuid-and-notify</link><description>I&amp;#39;ve been following the custom service nAN-36 instructions and have it mostly working on my PCA10028 board, but I have two problems that I just can&amp;#39;t figure out. I&amp;#39;m pretty sure they are related. 
 1st Problem 
 In advertising_init() if I implement</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 04 Sep 2015 05:23:27 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/8976/problem-with-custom-service-uuid-and-notify" /><item><title>RE: Problem with custom service UUID and Notify</title><link>https://devzone.nordicsemi.com/thread/33040?ContentTypeID=1</link><pubDate>Fri, 04 Sep 2015 05:23:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:06ad2b77-0abe-4895-bea1-e3931cd88f62</guid><dc:creator>Doug_H</dc:creator><description>&lt;p&gt;Thank you Anders! I haven&amp;#39;t tried modifying APP_ERROR_CHECK to trap these errors before a reset. I&amp;#39;ll do some research on how to do that now.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem with custom service UUID and Notify</title><link>https://devzone.nordicsemi.com/thread/33039?ContentTypeID=1</link><pubDate>Thu, 03 Sep 2015 13:02:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5982747b-9870-4e3d-9907-0142a2717366</guid><dc:creator>Anders Strand</dc:creator><description>&lt;p&gt;Hey!&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;This is probably caused by the advertisement packet being longer than the maximum of 31 bytes. See &lt;a href="https://devzone.nordicsemi.com/question/75/whats-the-maximum-size-for-an-advertisement-package/?answer=76#post-id-76"&gt;this&lt;/a&gt;. Moving a 128 UUID to the scan response packet is normally a good solution. The continous reset loop is caused by the default APP_ERROR_CHECK. If you do not alter it, or #define DEBUG, it will reset the chip. You should always check the return codes of softdevice calls, or most function calls in general :)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;It seems you have solved this yourself.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Problem with custom service UUID and Notify</title><link>https://devzone.nordicsemi.com/thread/33038?ContentTypeID=1</link><pubDate>Wed, 02 Sep 2015 08:55:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:317b1990-a8b0-437c-8fa4-94f37df36aa5</guid><dc:creator>Doug_H</dc:creator><description>&lt;p&gt;I have resolved part of the problem. The call to ble_on_button_change() handler was hanging because I was calling it from a GPIOTE ISR which is not allowed. I modified the implementation to use the app_scheduler() to move the calling context to main and it works fine now. The system still however hangs on advertising_init() if I try and populate the service UUIDs like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; ble_uuid_t adv_uuids[] = {{LBS_UUID_SERVICE, m_lbs.uuid_type}};    

 advdata.uuids_complete.uuid_cnt = sizeof(adv_uuids) / sizeof(adv_uuids[0]);

 advdata.uuids_complete.p_uuids  = adv_uuids;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If I put the service UUID in the Scan response packet it works fine. But it hangs if I put it in the in the initial advertising data packet. I don&amp;#39;t know why.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>