<?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>How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/10676/how-to-save-bonding-data-and-reuse-it-at-power-on</link><description>Hi, 
 I am developing an application on nrf51822 chip. I have set 
 #define SEC_PARAM_MITM 0
#define SEC_PARAM_IO_CAPABILITIES BLE_GAP_IO_CAPS_NONE
 
 Also i am developing an iOS application to talk to this device.
When my application is running</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 08 Dec 2015 14:30:08 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/10676/how-to-save-bonding-data-and-reuse-it-at-power-on" /><item><title>RE: How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/thread/39850?ContentTypeID=1</link><pubDate>Tue, 08 Dec 2015 14:30:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d7a86d67-395f-4160-a5b9-056ee603fc84</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi SumitS,&lt;/p&gt;
&lt;p&gt;The ble_app_gls does use device_manager_peripheral.c and that use flash to store bond information. You can test by do bonding, disconnect, reset the board and connect again.&lt;/p&gt;
&lt;p&gt;You can have a look at &lt;a href="https://devzone.nordicsemi.com/question/15271/how-can-i-write-10kb-of-data-to-internal-flash/?answer=17300#post-id-17300"&gt;this example&lt;/a&gt;. It&amp;#39;s simple example on how to use the pstorage.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/thread/39849?ContentTypeID=1</link><pubDate>Tue, 08 Dec 2015 04:02:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f561300-0850-40ce-9945-1faa97ec5987</guid><dc:creator>SumitS</dc:creator><description>&lt;p&gt;Thanks. I can use the device manager as it is. Currently i am using the sample ble_gls code. In that it is not storing the bond information. Is there any sample code or example which shows how to use the p_storage. Or what changes i need to make in the existing code.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/thread/39848?ContentTypeID=1</link><pubDate>Mon, 07 Dec 2015 13:40:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:24fc32c8-514c-40a7-948a-24089180eeaf</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi SumitS,&lt;/p&gt;
&lt;p&gt;Could you let me know why don&amp;#39;t you want to store the bond information on the nRF51 flash ? instead of your external EEPROM ?&lt;/p&gt;
&lt;p&gt;If you want to handle the data yourself, please have a look at the ble_app_template in nRF51 SDK v8.0 where we handle bonding without the device manager/peer manager. But in that example we don&amp;#39;t store the data in flash though.&lt;/p&gt;
&lt;p&gt;You should store p_sec_keyset, which is the keyset you provide when you call sd_ble_gap_sec_params_reply() in BLE_GAP_EVT_SEC_PARAMS_REQUEST.The p_sec_keyset will get the keys when the bonding process finished, BLE_GAP_EVT_AUTH_STATUS event. You should store the keys after you receive this event.&lt;/p&gt;
&lt;p&gt;After your reboot, you should read the keys out from flash and feed the keys to sd_ble_gap_sec_info_reply() call when the previously bonded central re-connect and re-bond (BLE_GAP_EVT_SEC_INFO_REQUEST event).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/thread/39847?ContentTypeID=1</link><pubDate>Sat, 05 Dec 2015 07:24:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4bc36c26-aa42-4ed3-a209-4553f3285b88</guid><dc:creator>SumitS</dc:creator><description>&lt;p&gt;So do i need to replace the pstorage part by my EEPROM module or is the code doing all this by itself?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to save bonding data and reuse it at power-on</title><link>https://devzone.nordicsemi.com/thread/39846?ContentTypeID=1</link><pubDate>Sat, 05 Dec 2015 05:24:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5a3bf4bc-a37f-4ebd-8a3b-6d6d7cff47f0</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Nordic has a whole device manager library which does exactly this, there&amp;#39;s examples, they use the pstorage_manager to store bonding information and retrieve it again. You should start by checking out all these examples.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>