<?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>1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/74034/1-1-permanent-connection-between-central-and-peripheral</link><description>Hello, I am trying to implement 1-1 connection between a central and a peripheral, with these (classic) requirements : - when starting central, scan for any peripheral with a given name - connect to it =&amp;gt; peripheral does not advertise anymore - when central</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 22 Apr 2021 08:38:46 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/74034/1-1-permanent-connection-between-central-and-peripheral" /><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/306248?ContentTypeID=1</link><pubDate>Thu, 22 Apr 2021 08:38:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:19a8eb62-825b-4d88-a95e-8ca7ce6427a4</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]I was indeed testing with nRF Connec. I see that I can able a bond from nRF Connect, but how can I initiaite pairing without bonding ?[/quote]
&lt;p&gt;&lt;span&gt;Click the settings button for the device in nRF Connect for Desktop, select &amp;quot;Pair&amp;quot;.&amp;nbsp;Then, click &amp;quot;Pair&amp;quot;. Wait until the pair is established before you continue.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/268263.PNG" /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]But I don&amp;#39;t see any sdk examples using these parameters. Do you have an example application that is not provided with the SDK ?[/quote]
&lt;p&gt;Unfortunately, we don&amp;#39;t have that, but you can modify the security parameters&lt;span&gt;&amp;nbsp;of&amp;nbsp;&lt;/span&gt;the&amp;nbsp;&lt;a title="Template Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_template.html?cp=7_1_4_2_2_23"&gt;Template Application&lt;/a&gt;&amp;nbsp;to achieve that.&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]The goal is to use my central device which is a NRF52832. From there, how can I initiate pairing without bonding ? What example can I look at ?[/quote]
&lt;p&gt;&amp;nbsp;You can take a look at the&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hrc.html"&gt;BLE Heart Rate Collector Example&lt;/a&gt;&amp;nbsp;which initials bonding from central with &lt;span&gt;pm_conn_secure&lt;/span&gt;. The example is using LESC pair &lt;span&gt;parameters&lt;/span&gt;, but the procedure is the same.&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]is there a way to connect to a bonded non-advertising peripheral ? How ?[/quote]
&lt;p&gt;No, the&amp;nbsp;&lt;span&gt;peripheral has to&amp;nbsp;advertise after disconnect.&lt;/span&gt;&lt;/p&gt;
[quote user="QuentinFarizon"]how can I implement a 1-1 connection between a central and peripheral, that supports disconnections from either side ?[/quote]
&lt;p&gt;&amp;nbsp;Did you play around&amp;nbsp;&lt;a title="Heart Rate Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hrs.html?cp=7_1_4_2_2_13"&gt;Heart Rate Application&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hrc.html"&gt;BLE Heart Rate Collector Example&lt;/a&gt;? The examples support pair with whitelist which can restrict the specific connection.&amp;nbsp; After disconnecting with the central (hrs_c), the peripheral (hrs) will adverse again. This might help your issue.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-Amanda H.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/306244?ContentTypeID=1</link><pubDate>Thu, 22 Apr 2021 08:21:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b13b1227-d5a3-4fe3-a9c4-ad29c8a0c1ad</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;Ok I succeeded with JustWorks bonding. I guess it&amp;#39;s not possible with &amp;quot;pairing, no bonding&amp;quot;.&lt;br /&gt;&lt;br /&gt;Peripheral still advertises when central disconnnects, but refuses all connections.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/306184?ContentTypeID=1</link><pubDate>Wed, 21 Apr 2021 16:50:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:80aafa1e-148d-44c6-b20f-0eb50f385391</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;To try to make some progress, I have tried using bonding on my perihperal and to iniate bonding from my central (or from nRF connect).&lt;br /&gt;I have looked at ble_app_hids_mouse that does exactly that.&lt;br /&gt;&lt;br /&gt;What I don&amp;#39;t get is that once the central disconnects, the peripheral does not advertise, so it can&amp;#39;t reconnect ...&amp;nbsp;&lt;br /&gt;Or is there a way to connect to a bonded non-advertising peripheral ? How ?&lt;br /&gt;&lt;br /&gt;I feel like I&amp;#39;m still at the start of the conversation : how can I implement a 1-1 connection between a central and peripheral, that supports disconnections from either side ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/306115?ContentTypeID=1</link><pubDate>Wed, 21 Apr 2021 12:38:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f9fa91f5-9ab0-4221-9006-e49ce23cd174</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;I was indeed testing with nRF Connec. I see that I can able a bond from nRF Connect, but how can I initiaite pairing without bonding ?&lt;br /&gt;&lt;br /&gt;On the peripheral, I have configured&amp;nbsp;pm_sec_params_set with the &amp;quot;Pairing, no bonding&amp;quot; configuration (from&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v17.0.2%2Flib_pm_usage.html&amp;amp;cp=7_1_3_2_7_2"&gt;https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v17.0.2%2Flib_pm_usage.html&amp;amp;cp=7_1_3_2_7_2&lt;/a&gt;)&lt;br /&gt;But I don&amp;#39;t see any sdk examples using these parameters. Do you have an example application that is not provided with the SDK ?&lt;br /&gt;&lt;br /&gt;The goal is to use my central device which is a NRF52832. From there, how can I initiate pairing without bonding ? What example can I look at ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305738?ContentTypeID=1</link><pubDate>Tue, 20 Apr 2021 08:16:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2473a2a8-e18e-472c-a17d-b9dc59a11fb8</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;What is your central device? Does it initial bond? If you are using&amp;nbsp;&lt;span&gt;ble_app_hids_mouse, see&lt;/span&gt;&amp;nbsp;&lt;a title="HID Mouse Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hids_mouse.html?cp=7_1_4_2_2_16"&gt;HID Mouse Application&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305548?ContentTypeID=1</link><pubDate>Mon, 19 Apr 2021 13:00:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7e66a105-a21d-446c-8a2a-e79838deac71</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;Sorry, this is a typo from my side : I use&amp;nbsp;pm_sec_params_set after&amp;nbsp;pm_init with the &amp;quot;&lt;b&gt;Pairing, no bonding&lt;/b&gt;&amp;quot; configuration.&lt;br /&gt;&lt;br /&gt;My question still stands,&amp;nbsp;&lt;span&gt;I am never called on PM event PM_EVT_PEER_DATA_UPDATE_SUCCEEDED&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305508?ContentTypeID=1</link><pubDate>Mon, 19 Apr 2021 11:52:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d07072f0-6546-424b-a5d3-4b759cd4eb68</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]I used the&amp;nbsp;&lt;span&gt;&amp;quot;No pairing/bonding&amp;quot; mode.&lt;/span&gt;[/quote]
&lt;p&gt;You need to enable pair or bond to&amp;nbsp;&lt;span&gt;call&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/group__peer__manager.html#gac27a2cc39be9fce1bd866ba4c6b18349"&gt;pm_sec_params_set&lt;/a&gt;. See&amp;nbsp;&lt;span&gt;Peer Manager/&lt;/span&gt;&lt;a title="Usage" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_pm_usage.html?cp=7_1_3_2_7_2"&gt;Usage&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_pm_usage.html#lib_pm_usage_security"&gt;Security parameters&lt;/a&gt;&amp;nbsp;docs&lt;span&gt;.&lt;/span&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305330?ContentTypeID=1</link><pubDate>Fri, 16 Apr 2021 14:54:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8c6d971f-a9df-4b9d-bcdf-6e89ca941dc1</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;Ok so on the peripheral I added the Perr Manager + whitelisting, based on ble_app_hids_mouse.&lt;br /&gt;&lt;br /&gt;However, I am never called on PM event PM_EVT_PEER_DATA_UPDATE_SUCCEEDED, which calls the whitelist_set in hids_mouse.&lt;br /&gt;In fact, I&amp;#39;m getting no events in&amp;nbsp;pm_evt_handler&lt;br /&gt;&lt;br /&gt;I have checked that peer manager is initialized&lt;br /&gt;I have set&amp;nbsp;PM_LOG_ENABLED, but I don&amp;#39;t see any logs pertaining to PM or errors.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;I used the&amp;nbsp;&lt;span&gt;&amp;quot;No pairing/bonding&amp;quot; mode.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305227?ContentTypeID=1</link><pubDate>Fri, 16 Apr 2021 08:22:37 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:41fa8172-6fc4-4057-883b-0d0f5a931405</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;You would need to use bonding and whitelisting so that the devices will reject connection from devices outside of the whitelist.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;This feature is supported by the softdevice and implemented in the peer manager libary:&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_pm_functionality.html?cp=7_1_3_2_7_1_2#lib_pm_functionality_whitelist"&gt;https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_pm_functionality.html?cp=7_1_3_2_7_1_2#lib_pm_functionality_whitelist&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You can refer to our example ble_app_hids_mouse (or keyboard). In the example, after bonding we will do directed advertising and after that will do whitelisting advertising,&amp;nbsp; after the whitelist advertising timeout, it will advertise in normal mode.&amp;nbsp;&lt;br /&gt;To be able to make sure there will be no other device to connect to your device, you can disable the timeout to normal mode. Only advertise in whitelisting mode.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305208?ContentTypeID=1</link><pubDate>Fri, 16 Apr 2021 06:28:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:18c482e0-75e8-4e36-84b2-4823e0a9718c</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;Is it then possible for the peripheral to forbid connections from other centrals ?&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:inherit;"&gt;&amp;nbsp;How do you suggest to implement the fact that the peripheral is &amp;quot;reserved&amp;quot; for a given previously connected central?&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305207?ContentTypeID=1</link><pubDate>Fri, 16 Apr 2021 06:24:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a22ffc68-c43c-4215-8760-aea773881e22</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&amp;nbsp;&lt;/p&gt;
[quote user="QuentinFarizon"]If the peripheral doesn&amp;#39;t advertise, isn&amp;#39;t it possible for the central to connect using the peer address.[/quote]
&lt;p&gt;&lt;span&gt;A peripheral device broadcasts info about itself using advertising. The central device will scan for advertisements, and analyze the advertisements found in the scan result.&lt;/span&gt;&lt;/p&gt;
[quote user="QuentinFarizon"]I didn&amp;#39;t meant a perihperal reset, I meant a peer reset (to allow the peripheral to be &amp;quot;free&amp;quot; and be scannable/connectable by another central)[/quote]
&lt;p&gt;You can take a look at this&amp;nbsp;&lt;a title="Bond Management Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_bms.html?cp=7_1_4_2_2_5"&gt;Bond Management Application&lt;/a&gt;&amp;nbsp;which&amp;nbsp;you could write a command to&amp;nbsp;to the Bond Management Service Control Point Characteristic (0x2AA4) to delete the current bond.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305164?ContentTypeID=1</link><pubDate>Thu, 15 Apr 2021 16:30:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3cb828af-477c-48bd-928d-53e39806c91f</guid><dc:creator>QuentinFarizon</dc:creator><description>&lt;p&gt;&amp;gt;&amp;nbsp;&lt;span&gt;I doubt that How the peripheral knows the central is power off and on to advertise or not.&lt;br /&gt;The peripheral can know the central disconnected.&amp;nbsp; &amp;nbsp;&lt;br /&gt;&lt;/span&gt;If the peripheral doesn&amp;#39;t advertise, isn&amp;#39;t it possible for the central to connect using the peer address.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;gt;&amp;nbsp;&lt;span&gt;You could&amp;nbsp;&lt;/span&gt;&lt;span&gt;send strings to the peripheral and handle it to execute&amp;nbsp;&lt;/span&gt;&lt;span&gt;NVIC_SystemReset();&lt;br /&gt;&lt;/span&gt;I didn&amp;#39;t meant a perihperal reset, I meant a peer reset (to allow the peripheral to be &amp;quot;free&amp;quot; and be scannable/connectable by another central)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: 1-1 permanent connection between central and peripheral</title><link>https://devzone.nordicsemi.com/thread/305113?ContentTypeID=1</link><pubDate>Thu, 15 Apr 2021 13:09:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb7cc102-c3bb-4c89-9bf1-41edc575ef16</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user=""]- when central is powered down, peripheral must not advertise&lt;br /&gt;- when central is powered up with a peer stored, it should connect to it[/quote]
&lt;p&gt;I doubt that How the peripheral knows the central is power off and on to advertise or not.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
[quote user=""]A)&amp;nbsp;From what I gather from the documentation, I guess the correct way to implement this is with the peer manager + whitelist with a maximum link of 1. Is this correct ? Is there a simpler/other API ?[/quote]
&lt;p&gt;That is correct. You can take a look&amp;nbsp;&lt;a title="HID Mouse Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hids_mouse.html?cp=7_1_4_2_2_16"&gt;HID Mouse Application&lt;/a&gt;&amp;nbsp;for&amp;nbsp;&lt;span&gt;whitelist, and &lt;a title="Heart Rate Application" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/ble_sdk_app_hrs.html?cp=7_1_4_2_2_13"&gt;Heart Rate Application&lt;/a&gt;&amp;nbsp;for&amp;nbsp;&lt;a title="Software Development Kit" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_peer_manager.html?resultof=%22%70%65%65%72%22%20%22%6d%61%6e%61%67%65%72%22%20%22%6d%61%6e%61%67%22%20"&gt;Peer Manager&lt;/a&gt;&amp;nbsp;and LESC pair. You might be interested in this similar &lt;a href="https://devzone.nordicsemi.com/support-private/support/267828"&gt;case&lt;/a&gt;.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
[quote user=""]B) Is the reconnect automatic at start with the peer manager ? If not, what is the function for that ? scan with whitelist ?[/quote]
&lt;p&gt;&lt;span&gt;&lt;/span&gt;No, you could scan and connect with the whitelist. See this &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/45034/scan-with-whitelist-vs-scan-filtering"&gt;post&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
[quote user=""]C) Is this possible with the &amp;quot;No pairing/bonding&amp;quot; mode of peer manager ? If not, is &amp;quot;Pairing, no bonding&amp;quot; the way to go ?[/quote]
&lt;p&gt;&amp;nbsp;Yes, see&amp;nbsp;&lt;a title="Security parameters" href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/lib_pm_usage.html?cp=7_1_3_2_7_2_1#lib_pm_usage_security"&gt;Security parameters&lt;/a&gt;&amp;nbsp;for&amp;nbsp;Pairing, no bonding.&lt;/p&gt;
[quote user=""]D) Is there a standard way for the central to indicate to the peripheral to reset peer or should I create a custom service for that ?[/quote]
&lt;p&gt;&amp;nbsp; You could&amp;nbsp;&lt;span&gt;send strings to the peripheral and handle it to execute&amp;nbsp;&lt;/span&gt;&lt;span&gt;NVIC_SystemReset();&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;-Amanda H.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>