<?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>BLE Pairing and binding</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/58794/ble-pairing-and-binding</link><description>use nrf52810 
 nRF5_SDK_15.3.0_59ac345\examples\ble_peripheral\ble_app_uart\pca10040e 
 How to initiate pairing and binding？ 
 Thanks！</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 09 Mar 2020 08:35:11 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/58794/ble-pairing-and-binding" /><item><title>RE: BLE Pairing and binding</title><link>https://devzone.nordicsemi.com/thread/238732?ContentTypeID=1</link><pubDate>Mon, 09 Mar 2020 08:35:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9ebd26fe-9f41-4c8f-91fd-3d1829969087</guid><dc:creator>Edvin</dc:creator><description>[quote user="hhhhhhok"]I actively delete my phone&amp;#39;s Bluetooth pairing.[/quote]
&lt;p&gt;&amp;nbsp;Ok. Why do you do that?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And if you do that, did you try the approach that I mentioned in my previous reply? I see that you get the event, but you have to do the function call that I proposed. Right now you are doing nothing.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t know exactly what causes the &amp;quot;Fatal error&amp;quot;, but try to define DEBUG in your preprocessor defines. It should then print what APP_ERROR_CHECK(err_code) that received an err_code != 0.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;BR,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE Pairing and binding</title><link>https://devzone.nordicsemi.com/thread/238570?ContentTypeID=1</link><pubDate>Fri, 06 Mar 2020 15:08:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:19372bb3-3329-4a82-9d0d-067538851a54</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Do you actively delete the bonding information on the phone side? Or does it happen &amp;quot;automatically&amp;quot;? How do you determine that it is deleted?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;It is possible to tell the nRF to accept pairing with already paired devices, so you could do that, but that doesn&amp;#39;t change the behavior of the phone. You would then have to pair every time you connect to the mobile phone.&lt;/p&gt;
&lt;p&gt;Does it happen on other phones as well? Or only that model in particular?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;When an already bonded device asks for a connection without the previous bonding data, the&amp;nbsp;PM_EVT_CONN_SEC_CONFIG_REQ should occur. As you see in the description of this event, it says:&lt;/p&gt;
&lt;p&gt;/**&amp;lt; @brief The peer (central) has requested pairing, but a bond already exists with that peer. Reply by calling @ref pm_conn_sec_config_reply before the event handler returns. If no reply is sent, a default is used. */&lt;/p&gt;
&lt;p&gt;This means that if this event is not handled, the pairing will be denied. What you need to call in this event is pm_conn_sec_config_reply(); with:&lt;/p&gt;
&lt;p&gt;pm_conn_sec_config_t * p_conn_sec_config, where pm_conn_sec_config.allow_repairing = true;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;But again, this only solves half of your issue. It doesn&amp;#39;t explain why the phone deletes the bonding data in the first place.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE Pairing and binding</title><link>https://devzone.nordicsemi.com/thread/238538?ContentTypeID=1</link><pubDate>Fri, 06 Mar 2020 13:36:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:22c7c619-ef3d-480e-9e9e-a2e3930c2568</guid><dc:creator>xixili</dc:creator><description>&lt;p&gt;I use&amp;nbsp;&lt;span&gt;SDK\examples\ble_peripheral\ble_app_gls,this example.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;After my pairing and binding is successful, the phone deletes the pairing information.&lt;/p&gt;
&lt;p&gt;Pairing the phone again will prompt NRF52810(Nordic_Glucose) to refuse to pair.&lt;/p&gt;
&lt;p&gt;What should i modify?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE Pairing and binding</title><link>https://devzone.nordicsemi.com/thread/238518?ContentTypeID=1</link><pubDate>Fri, 06 Mar 2020 12:51:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6981bd4e-135e-452e-9594-ffb41e53c240</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;If you look at the ble_app_gls example from the SDK\examples\ble_peripheral\ble_app_gls, this example will show you how to use the peer manager to pair and bond with a pairing key.&lt;/p&gt;
&lt;p&gt;There are quite a few files that you need to add in, so be patient. Add the peer manager files that are used in the ble_app_gls example, compile, and check what functions/header files that are missing. When it says that some functions are missing, look in the ble_app_gls example in what file that function is defined in, and add that file. You probably also need to add some defines from sdk_config.h. It is typically the guards that enables the modules that you add in.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Let me know if you are stuck somewhere.&lt;/p&gt;
&lt;p&gt;Best Regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>