<?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 config LESC</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/101940/how-to-config-lesc</link><description>Hi： 
 I use SDK17.1.0. 
 Example ble_app_hrs. 
 Config: 
 #define SEC_PARAM_LESC 1 /**&amp;lt; LE Secure Connections enabled. */ #define SEC_PARAM_KEYPRESS 1 /**&amp;lt; Keypress notifications not enabled. */ 
 uint8_t const key[]=&amp;quot;123456&amp;quot;; ble_opt_t opt; opt.gap_opt</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 17 Jul 2023 11:22:20 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/101940/how-to-config-lesc" /><item><title>RE: How to config LESC</title><link>https://devzone.nordicsemi.com/thread/436720?ContentTypeID=1</link><pubDate>Mon, 17 Jul 2023 11:22:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:38652ece-8ff4-438f-bcb7-2fc8f3a399bc</guid><dc:creator>Vidar Berg</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;To enable passkey pairing with a static key, you can apply the following changes in main.c:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/hrs.diff"&gt;devzone.nordicsemi.com/.../hrs.diff&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Notice I changed the security level for the characteristics in service_init(). This forces the central to pair with your device before it can access the characteristics.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Vidar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>