<?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>Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/12755/packet-lost-during-stream-of-data-transmission---connection-interval-issue</link><description>SDK Version: 9.0.0 Softdevice: S110 v8.0.0 
 I&amp;#39;m currently trying to send streams of data from an Android app to a nrf51. However, at some point, Android side writes to the characteristic which the nrf51 does not acknolwedge. 
 How it works: 
 
 Android</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 04 May 2016 16:28:09 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/12755/packet-lost-during-stream-of-data-transmission---connection-interval-issue" /><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48456?ContentTypeID=1</link><pubDate>Wed, 04 May 2016 16:28:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ce9ecc25-19ab-4cff-bd6c-6ee43743ae0e</guid><dc:creator>Christopher</dc:creator><description>&lt;p&gt;You are welcome, hope this help !&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48458?ContentTypeID=1</link><pubDate>Wed, 04 May 2016 11:12:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:53361aa6-7b32-4c66-a44f-61847200c829</guid><dc:creator>Maz Shar</dc:creator><description>&lt;p&gt;Sorry, yes I mean longer time in sleep mode. Thank you for all the extremely useful help, metch!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48457?ContentTypeID=1</link><pubDate>Tue, 03 May 2016 18:16:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1cc6f01f-8798-4bf1-83dc-44dcaa8884d7</guid><dc:creator>Christopher</dc:creator><description>&lt;p&gt;Yes, this is a common use case. I guess you want 30ms in sleep mode and 15ms when communicating... In sleep mode, you could even request a slower interval (= less power consumption), but please note that it takes some time (the negotiation requires several slots) to change from a slow to a faster interval.&lt;/p&gt;
&lt;p&gt;From a central peripheral, you can ask for a connection parameter update request to the remote device. From the peripheral side, you can use the &lt;code&gt;sd_ble_gap_conn_param_update&lt;/code&gt; function, &lt;a href="http://developer.nordicsemi.com/nRF51_SDK/nRF51_SDK_v8.x.x/doc/8.0.0/s120/html/a00703.html#gaf89b434841998ab384e0612dca9e12f8"&gt;see this link&lt;/a&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48455?ContentTypeID=1</link><pubDate>Tue, 03 May 2016 16:33:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b8895102-c4b5-4732-8494-2cb6026b38ea</guid><dc:creator>Maz Shar</dc:creator><description>&lt;p&gt;Thank you, metch. I have now implemented BLE connection parameters and with a 30ms interval time, I can achieve a throughput which is much closer to what we want!&lt;/p&gt;
&lt;p&gt;Is there a way of dynamically renegotiating connection parameters through software lifecycle? E.g. we want 15ms in sleep mode and then 30ms when communicating?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48453?ContentTypeID=1</link><pubDate>Sat, 30 Apr 2016 09:56:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:91bf7017-2306-4d36-b85b-bd63288b9bd0</guid><dc:creator>Christopher</dc:creator><description>&lt;p&gt;They are many posts on the devzone explaining how to calculate the BLE throughput you can achieve. This highly depends on the SoftDevice you use, the sender capabilities (android phone) and of the course the connection interval.&lt;/p&gt;
&lt;p&gt;Short calculation: 1 packet of 20 bytes each 7.5ms = 2666 B/s (using notifications, S110, if the Android phone supports a minimum 7.5ms connection interval)
64 * 1024B / 2666 B/s = 25 seconds&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48454?ContentTypeID=1</link><pubDate>Fri, 29 Apr 2016 16:05:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8270a556-1058-425c-9157-ffa62eb6ce9e</guid><dc:creator>Maz Shar</dc:creator><description>&lt;p&gt;@metch I tried your first suggestion. This did indeed help. I no longer have problems with records not being received, and the stream of data goes through to completion. Although the throughput is better, it&amp;#39;s not what we want. We would like to send 64k in 2 minutes, is this achievable?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48452?ContentTypeID=1</link><pubDate>Wed, 13 Apr 2016 18:22:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0906b31f-868d-4073-b37d-8680831c401e</guid><dc:creator>Maz Shar</dc:creator><description>&lt;p&gt;Thank you. I will give this a try and get back to you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Packet lost during stream of data transmission - connection interval issue?</title><link>https://devzone.nordicsemi.com/thread/48451?ContentTypeID=1</link><pubDate>Wed, 23 Mar 2016 19:44:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:12d52440-3fc6-4af3-a7dc-74f65a5bb8ce</guid><dc:creator>Christopher</dc:creator><description>&lt;p&gt;First, I am not sure your uses the right primitive here... In my opinion, if you need to write data to the peripheral and you want to be sure it has received the data (I assume your Android phone has the central role), you should use a confirmed service (with response) instead of doing this manually by sending a notification back to the central device. The SoftDevice can manage this for you.&lt;/p&gt;
&lt;p&gt;Have a look at &lt;a href="https://devzone.nordicsemi.com/question/17399/how-to-give-response-after-client-writes-to-characteristic/?answer=17438#post-id-17438"&gt;this post from Nordic&lt;/a&gt; which describes the GATTS Write Commands and Request. Some sequence diagrams &lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.s132.api.v2.0.0%2Fgroup___b_l_e___g_a_t_t_s___w_r_i_t_e___r_e_q___n_o___a_u_t_h___m_s_c.html"&gt;are available here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I do not know the BLE throughput you need/want to achieve, but first try to set a connection interval &amp;gt;= 20 ms. If you use a write request (with response) instead of a write command and a notification you will be able to send BLE packets faster.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>