<?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>Issue with 2 centrals and single peripheral</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/49112/issue-with-2-centrals-and-single-peripheral</link><description>I am using the UART central, integrated with peer manager and UART peripheral application from the SDK 15.3 on our custom hardware. I have 2 centrals running exactly same firmware and one peripheral device that sends periodic data. In our system, both</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 09 Jul 2019 09:27:57 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/49112/issue-with-2-centrals-and-single-peripheral" /><item><title>RE: Issue with 2 centrals and single peripheral</title><link>https://devzone.nordicsemi.com/thread/197311?ContentTypeID=1</link><pubDate>Tue, 09 Jul 2019 09:27:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f642705-121f-45f8-818c-b0ab6f5bc8fa</guid><dc:creator>Mttrinh</dc:creator><description>&lt;p&gt;It is weird that it isn&amp;#39;t timing out after some time. Which event do you get when you get a match? Is this event triggered NRF_BLE_SCAN_EVT_CONNECTED?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Could you try changing this value&amp;nbsp;NRF_BLE_SCAN_SCAN_DURATION?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Issue with 2 centrals and single peripheral</title><link>https://devzone.nordicsemi.com/thread/196014?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2019 13:16:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:45b7e27c-a85e-44cb-9842-0cec2167ac10</guid><dc:creator>prodey</dc:creator><description>&lt;p&gt;Just to clarify above reply : &amp;quot;&lt;span&gt;&lt;em&gt;In this condition, if I restart the peripheral, the central gets out of this condition and periodically starts&amp;nbsp;getting the&amp;nbsp;BLE_NUS_C_EVT_NUS_TX_EVT event&lt;/em&gt;&amp;quot;. &lt;span style="text-decoration:underline;"&gt;In this condition, the other central gets into a normal scanning mode.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Issue with 2 centrals and single peripheral</title><link>https://devzone.nordicsemi.com/thread/196012?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2019 13:13:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c255a4cf-104e-4675-b395-7944ecdc8318</guid><dc:creator>prodey</dc:creator><description>&lt;p&gt;I do not get any error codes on the central device. I tried to probe all the timeout events and&amp;nbsp;&lt;span&gt;BLE_GAP_EVT_DISCONNECTED event through LED indicators on our hardware, but none of these are hit once the device gets a match. In this condition, if I restart the peripheral, the central gets out of this condition and periodically starts&amp;nbsp;getting the&amp;nbsp;BLE_NUS_C_EVT_NUS_TX_EVT event. It seems, when there is a device name match, the central waits forever till it receives BLE packets from the exact same peripheral device that caused the match without ever getting into a timeout.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;My constant&amp;nbsp;NRF_BLE_SCAN_SUPERVISION_TIMEOUT is set to 1000 which I guess is 10 sec timeout. I tried to change this value but it does not affect this behavior. Our periodic messages from peripheral are being sent at 10 ms.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I can handle this on the application side. I start a timer set for 1 sec on device name match and check for a global variable that increments in&amp;nbsp;ble_nus_c_evt_handler(). If it has not incremented for 1 sec, I reset the device trough sd_nvic_SystemReset(). With that, the central&amp;nbsp;starts normal scan again and is ready to pair with any other peripheral.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;However,&amp;nbsp;&lt;/span&gt;&lt;span&gt;I believe&amp;nbsp;there is a better way to handle this than such frequent resets to the device. &lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Please suggest.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Issue with 2 centrals and single peripheral</title><link>https://devzone.nordicsemi.com/thread/195853?ContentTypeID=1</link><pubDate>Tue, 02 Jul 2019 08:13:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3962d33e-295a-489b-8f11-b024b9af474c</guid><dc:creator>Mttrinh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Sorry for the late response.&lt;/p&gt;
&lt;p&gt;Do you get any error codes when the device is stuck?&lt;/p&gt;
&lt;p&gt;If both get centrals are getting a match, the one central that doesn&amp;#39;t establish a connection with the peripheral should get a timeout. After the supervision timeout has passed, you should get a&amp;nbsp;&lt;span&gt;BLE_GAP_EVT_DISCONNECTED event. What is your supervision timeout set to?&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>