<?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>enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/12382/enable-disable-indication-issue-when-characteristic-is-already-sending</link><description>I&amp;#39;m working on a program which sends 20 kb of data (sending 16 byte at a time) with one condition which is that indication should be enabled first. the first function checks if indication is enabled on characteristic before starting transfer. when when</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 08 Mar 2016 15:00:51 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/12382/enable-disable-indication-issue-when-characteristic-is-already-sending" /><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46817?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 15:00:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b12aac83-39bf-453c-9532-385d45fb00a6</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;@makouda could you please upload a &lt;a href="https://www.nordicsemi.com/eng/nordic/download_resource/26386/14/57771838"&gt;sniffer trace&lt;/a&gt; containing this problem?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46815?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 13:36:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:860b4e3a-0b31-4327-b927-a8e308ec73ae</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Go and report a bug against the softdevice then because the indication is guaranteed to go out if it&amp;#39;s accepted and the peripheral is required to reply to it so the stack is required to tell you the reply has been received and the buffer is free. There isn&amp;#39;t even an error code involved, the peripheral replies with the standard response.&lt;/p&gt;
&lt;p&gt;Ensure you have a sniffer trace of the connection to accompany your bug report to show what&amp;#39;s happening.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46816?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 13:14:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:80305754-05a3-4390-a857-c1bc1d7fcef5</guid><dc:creator>makouda</dc:creator><description>&lt;p&gt;im waiting for indication event and I can see that it&amp;#39;s not called at all. the connection is always established.     &lt;code&gt;case BLE_GATTS_EVT_HVC: indication_pending = false;&lt;/code&gt; . this flag is set to false if &lt;code&gt;NRF_ERROR_INVALID_STATE&lt;/code&gt; is returned on the send function. so the the state is valid&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46814?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 12:34:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1acad8cd-5557-421f-9dd8-2b8df3bf8edb</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;For the third time, if the indication is accepted by the stack it will go out, if it goes out a reply will come back, when the reply comes back the buffer will be released and the callback will occur. There is no race condition, it doesn&amp;#39;t matter if indications are turned off, as long as the link is up the client will reply. This is all in the bluetooth spec.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46813?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 12:27:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9cd8f7cb-82df-4f73-ab90-154c707e95cc</guid><dc:creator>makouda</dc:creator><description>&lt;p&gt;How about in case the indications are on. Then it goes out and then I disable them. The out message is received  anyway???&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46812?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 12:17:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e09b5907-20a4-4511-bd54-d39cb2eef6ee</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;What you&amp;#39;re asking doesn&amp;#39;t make any sense. There isn&amp;#39;t a lost indication, if indications haven&amp;#39;t been turned off by the time you send yours, it goes out and it gets ack&amp;#39;ed. if they have been turned off then you get the invalid state call and it doesn&amp;#39;t go out at all.&lt;/p&gt;
&lt;p&gt;And most likely that invalid state error is why you &amp;#39;hang&amp;#39;, because you are, as I suggested earlier, ending up in the error handler. You really would do yourself an awful lot of good if you put a breakpoint in your error handler or learned to hit the break button in your debugger, you&amp;#39;d find the cause very much faster.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46811?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 11:35:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:45b6fc0c-0ab0-400f-aa88-2ffc6dbdc2a4</guid><dc:creator>makouda</dc:creator><description>&lt;p&gt;this is what im doing in my code, I check first that indication are enabled on &lt;code&gt;is_flash_data_indication_enabled&lt;/code&gt; . when I disable indication on the phone side, is there any event triggered to notify me that last indication is lost, so that I can send another one???&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46810?ContentTypeID=1</link><pubDate>Tue, 08 Mar 2016 11:33:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8ed36b04-6fb3-4ead-8b18-6eb5ec892769</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;If you try to send an indication after indications has been disabled, &lt;a href="http://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.s130.api.v1.0.0%2Fgroup___b_l_e___g_a_t_t_s___f_u_n_c_t_i_o_n_s.html&amp;amp;cp=2_7_2_1_1_2_3_5_2&amp;amp;anchor=ga313fe43c2e93267da668572e885945db"&gt;sd_ble_gatts_hvx(..)&lt;/a&gt; will return the error NRF_ERROR_INVALID_STATE. You could for example verify if that causes some problems.&lt;/p&gt;
&lt;p&gt;Indications (and notifications) can only be enabled and disabled by the client (in this case the central). The reason is the following: when the server (often the peripheral) updates values to the client, the client has to be ready to receive these updates.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: enable / disable indication issue when characteristic is already sending</title><link>https://devzone.nordicsemi.com/thread/46809?ContentTypeID=1</link><pubDate>Mon, 07 Mar 2016 23:37:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:13c147ef-9e38-44e0-bca2-7a1b7431412a</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Start with the usual question &amp;quot;whole system hang&amp;quot;. Have you put a breakpoint in the error handler or used the debugger to break and find out if you are in the error handler or one of the fault handlers? That&amp;#39;s the first thing to do when &amp;#39;the whole system hang&amp;#39;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>