<?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>Device Get shut down when after getting Insufficient Authorization</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/2007/device-get-shut-down-when-after-getting-insufficient-authorization</link><description>Hi,
I am using the following security level for my nRF5188 device. 
 
BLE_GAP_CONN_SEC_MODE_SET_ENC_WITH_MITM(&amp;amp;bas_init.battery_level_char_attr_md.cccd_write_perm);
BLE_GAP_CONN_SEC_MODE_SET_OPEN(&amp;amp;bas_init.battery_level_char_attr_md.read_perm);
BLE_GAP_CONN_SEC_MODE_SET_ENC_WITH_MITM</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 31 Mar 2014 13:21:06 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/2007/device-get-shut-down-when-after-getting-insufficient-authorization" /><item><title>RE: Device Get shut down when after getting Insufficient Authorization</title><link>https://devzone.nordicsemi.com/thread/8597?ContentTypeID=1</link><pubDate>Mon, 31 Mar 2014 13:21:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a3fa0ac0-aa38-4286-a0f1-fc6a369356e7</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Khandker, I don&amp;#39;t see any issue with the code, could you upload the whole project so that I can compile and run here ?
Also please answer: &amp;quot;You said &amp;quot;device get shut down when i disconnect&amp;quot;, does this mean the device remains in connection with the phone until you press disconnect ?&amp;quot;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Get shut down when after getting Insufficient Authorization</title><link>https://devzone.nordicsemi.com/thread/8596?ContentTypeID=1</link><pubDate>Sun, 30 Mar 2014 04:53:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cff0a07d-0dd0-46cb-9c23-d07beb1314c1</guid><dc:creator>Khandker Mahmudur Rahman</dc:creator><description>&lt;p&gt;Hi,
Thanks for the response.
I am attaching my code here.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Device Get shut down when after getting Insufficient Authorization</title><link>https://devzone.nordicsemi.com/thread/8595?ContentTypeID=1</link><pubDate>Thu, 27 Mar 2014 13:59:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6a8162cb-e56d-4bfd-8a70-fe609e86fe69</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Khandker,&lt;/p&gt;
&lt;p&gt;I suspect there was a bug in the way your firmware handle bonding and pairing. When the phone receives &amp;quot;Insufficient Authorization&amp;quot; error, it will perform pairing process to encrypt the link. And when you restart the device, it&amp;#39;s possible that the device automatically connect to the previous phone or start  directed advertising and that why it&amp;#39;s not visible to other devices (some app won&amp;#39;t show you the device advertise with directed advertising to another phone).&lt;/p&gt;
&lt;p&gt;You said &amp;quot;device get shut down when i disconnect&amp;quot;, does this mean the device remains in connection with the phone until you press disconnect ?&lt;/p&gt;
&lt;p&gt;Have you made sure you don&amp;#39;t put the device into deep sleep mode when BLE_GAP_EVT_DISCONNECTED event occurs ?&lt;/p&gt;
&lt;p&gt;If possible please send us your code.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>