<?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>Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/89012/connection-parameter-update-disconnection-on-windows</link><description>We have a device that works correctly on iOS, Android, mac, but disconnects on some Windows machines. We use nRF5 SDK 17.1.0 and s132 7.2.0. The disconnect occurs after the supervision timeout following a connection parameter update, whether successful</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 22 Jun 2022 11:07:58 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/89012/connection-parameter-update-disconnection-on-windows" /><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/373637?ContentTypeID=1</link><pubDate>Wed, 22 Jun 2022 11:07:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a36f7e8f-aac8-4d65-b910-d5f5c4a26198</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;In that case, it should be possible to load LTK from flash and insert into Wireshark. see &amp;quot;&lt;span class="item"&gt;&lt;a class="" title="Sniffing a connection between bonded devices" href="https://infocenter.nordicsemi.com/topic/ug_sniffer_ble/UG/sniffer_ble/action_bonded.html?cp=10_5_5_4"&gt;Sniffing a connection between bonded devices&amp;quot;&lt;/a&gt;.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;PM API to load bonding information for peer devices: &lt;span class="item"&gt;&lt;a class="" title="pm_peer_data_bonding_load" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/group__peer__manager.html?cp=8_1_6_2_16_50#gabf148a0bb89fadfaae7f93bbda4e93ef"&gt;pm_peer_data_bonding_load&lt;/a&gt;()&lt;/span&gt;&lt;/p&gt;
[quote userid="69018" url="~/f/nordic-q-a/89012/connection-parameter-update-disconnection-on-windows/373636"]so it may be just that it didn&amp;#39;t happen when they tried[/quote]
&lt;p&gt;I think so, unless the issue only occurs on the initial connection when bonding takes place.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="item"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span class="item"&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/373636?ContentTypeID=1</link><pubDate>Wed, 22 Jun 2022 10:58:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bfcfa793-82ec-4892-be62-6e09d1690247</guid><dc:creator>nrbrook</dc:creator><description>&lt;p&gt;Yes, I was also surprised. I&amp;#39;ve asked the remote guys to try again because this problem is somewhat intermittent, so it may be just that it didn&amp;#39;t happen when they tried.&lt;/p&gt;
&lt;p&gt;Yes we are bonding.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/373634?ContentTypeID=1</link><pubDate>Wed, 22 Jun 2022 10:56:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a8ab30ab-1938-44f9-bbee-ebaa8876ba9c</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;It&amp;#39;s surprising that the paring method seems affect behavior as well. Are you doing bonding or do you pair on every connection?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/373623?ContentTypeID=1</link><pubDate>Wed, 22 Jun 2022 09:50:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3a437cd0-69cd-4edd-86fa-6d8a3f8f0cfe</guid><dc:creator>nrbrook</dc:creator><description>&lt;p&gt;We are trying to get a capture, but we use LESC. When using the debug key, Windows doesn&amp;#39;t accept the key and rejects the pairing request (we can use the sniffer successfully when connecting with iOS). If we disable LESC and use just works pairing, we can use the sniffer, but the problem doesn&amp;#39;t seem to occur. Any suggestions? Do you know of a way to get Windows to accept the LESC debug key?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/372963?ContentTypeID=1</link><pubDate>Fri, 17 Jun 2022 09:02:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fa6df207-d1cd-4d88-91ea-56261bf7549c</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;After a LMP_RESPONSE_TIMEOUT, the peripheral (nrf) will stop responding to the central so the central will end up with a supervision timeout.&lt;/p&gt;
[quote user="nrbrook"]&lt;p&gt;So perhaps it is nRF that times out first, and then Windows? I&amp;#39;ll try to get a sniffer capture.&lt;/p&gt;
&lt;p&gt;As I mentioned, if we send a packet after that connection parameter update response, Windows doesn&amp;#39;t disconnect.&lt;/p&gt;[/quote]
&lt;p&gt;Yes, it&amp;#39;s this part I don&amp;#39;t understand. I hope you are able to get a sniffer capture of it.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/372948?ContentTypeID=1</link><pubDate>Fri, 17 Jun 2022 08:15:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb074a05-80ee-4b78-81ff-9533c3a01b22</guid><dc:creator>nrbrook</dc:creator><description>&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/BT500S_2D00_6-June-16-v1.pcapng"&gt;devzone.nordicsemi.com/.../BT500S_2D00_6-June-16-v1.pcapng&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I think what might be happening is Windows sends an &amp;quot;LE Connection Update complete&amp;quot; packet from controller to host (in the attached which is a bit simpler):&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;727	42.195	controller	host	HCI_EVT	Rcvd LE Meta (LE Connection Update Complete)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;and then for some reason is expecting some communication from the other side after that. It disconnects after the supervision timeout after that:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;733	47.291	controller	host	HCI_EVT	Rcvd Disconnect Complete&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Because it thinks the connection has timed out, it doesn&amp;#39;t send a disconnection packet, and so on the nRF, the LL times out because Windows just stops communicating. Although I see the LMP_RESPONSE_TIMEOUT is when an LMP or LL transaction failed to respond within the timeout. But the nRF does get the connection parameters response:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;00&amp;gt; [00:01:01.128,234] &amp;lt;info&amp;gt; Bluetooth: Attempting connection param change, min: 50ms, max: 75ms, latency: 0, timeout: 5000ms
00&amp;gt; [00:01:01.411,682] &amp;lt;debug&amp;gt; Bluetooth: Connection parameters changed successfully for connection 0000
00&amp;gt; [00:01:01.411,712] &amp;lt;info&amp;gt; Bluetooth: Connection params updated for connection 0000: min 75ms, max 75ms, latency 0, timeout 5000ms
00&amp;gt; [00:01:01.501,708] &amp;lt;info&amp;gt; Bluetooth: Disconnected. conn_handle: 0x0, reason: BLE_HCI_STATUS_CODE_LMP_RESPONSE_TIMEOUT&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;So perhaps it is nRF that times out first, and then Windows? I&amp;#39;ll try to get a sniffer capture.&lt;/p&gt;
&lt;p&gt;As I mentioned, if we send a packet after that connection parameter update response, Windows doesn&amp;#39;t disconnect.&lt;/p&gt;
&lt;p&gt;I do use nrf_ble_gatt, but NRF_BLE_GATT_MTU_EXCHANGE_INITIATION_ENABLED is not defined in my project and so is disabled already.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/372926?ContentTypeID=1</link><pubDate>Fri, 17 Jun 2022 07:17:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dd516759-f356-4937-85b4-b4201227a171</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;BLE_HCI_STATUS_CODE_LMP_RESPONSE_TIMEOUT indicates that the Windows host failed to respond to a link layer control request issued by your peripheral. But I don&amp;#39;t understand how it could be tied to the connection parameter update.&lt;/p&gt;
&lt;p&gt;From the core spec. v5.3, vol. 6, part B:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1655448433676v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;Are you using the &lt;span&gt;&lt;a title="Experimental: GATT Module" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/lib_ble_gatt.html?cp=8_1_3_2_13"&gt;GATT Module&lt;/a&gt;&lt;/span&gt; to handle data length updates in your FW? In that case, please try to disable the NRF_BLE_GATT_MTU_EXCHANGE_INITIATION_ENABLED in sdk_config.h to see if it makes any difference if Windows is allowed to initiate the update procedure first.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/372870?ContentTypeID=1</link><pubDate>Thu, 16 Jun 2022 16:15:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5d38bb04-d0e2-4a8c-8633-d5f0be55e8c7</guid><dc:creator>nrbrook</dc:creator><description>&lt;p&gt;Hi Vidar,&lt;/p&gt;
[quote userid="4240" url="~/f/nordic-q-a/89012/connection-parameter-update-disconnection-on-windows/372849#372849"]Could you try again with the NRF_SDH_CLOCK_LF_ACCURACY set to 1 and NRF_SDH_CLOCK_LF_SRC 0 and see if it gives the same result?[/quote]
&lt;p&gt;They already are set to these values.&lt;/p&gt;
&lt;p&gt;I am debugging this remotely so it might be difficult to get a packet log from a sniffer, but I will try.&lt;/p&gt;
&lt;p&gt;However, I got debug logs from the device, and the disconnect reason on the nRF52832 is&amp;nbsp;BLE_HCI_STATUS_CODE_LMP_RESPONSE_TIMEOUT. Does this indicate that windows has not responded to the request?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connection parameter update disconnection on Windows</title><link>https://devzone.nordicsemi.com/thread/372849?ContentTypeID=1</link><pubDate>Thu, 16 Jun 2022 14:05:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a7335f5b-651c-4a34-b3ab-6b675912308a</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I do not think this is a known issue at least. Could you try again with the NRF_SDH_CLOCK_LF_ACCURACY set to 1 and NRF_SDH_CLOCK_LF_SRC 0 and see if it gives the same result? This may help rule out drift on the slow clock (either on the PC or on the device) as a possible cause. I also think it would be helpful to have a packet capture of the packets sent on-air if you have BLE sniffer on hand.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Vidar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>