<?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>Use Peripheral and Central UART (NUS service) example with pairing</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/94795/use-peripheral-and-central-uart-nus-service-example-with-pairing</link><description>In both examples have the callback functions that It does the pairing process. 
 The nRF52840 doesn&amp;#39;t have the security support enabled,. In this case Initiator / Responder of pairing were called No Imput / No Output, in this case Just Works and a connection</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 15 Dec 2022 16:11:40 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/94795/use-peripheral-and-central-uart-nus-service-example-with-pairing" /><item><title>RE: Use Peripheral and Central UART (NUS service) example with pairing</title><link>https://devzone.nordicsemi.com/thread/400919?ContentTypeID=1</link><pubDate>Thu, 15 Dec 2022 16:11:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ca35bd23-1909-4be3-ba64-e79cdb292331</guid><dc:creator>Offox</dc:creator><description>&lt;p&gt;Sigurd,&lt;br /&gt;&lt;br /&gt;It needs to work change the GATT permitions fo NUS service.&lt;br /&gt;&lt;br /&gt;Now the implemeted SMP callback funtions work.&lt;br /&gt;&lt;br /&gt;I will send the changed code:&lt;br /&gt;&lt;br /&gt;&lt;pre class="ui-code" data-mode="diff"&gt;diff --git a/nus.c b/nus.c
index dc36b4c..a1d2dd3 100644
--- a/nus.c
+++ b/nus.c
@@ -60,13 +60,13 @@ BT_GATT_SERVICE_DEFINE(nus_svc,
BT_GATT_PRIMARY_SERVICE(BT_UUID_NUS_SERVICE),
BT_GATT_CHARACTERISTIC(BT_UUID_NUS_TX,
BT_GATT_CHRC_NOTIFY,
- BT_GATT_PERM_READ,
+ BT_GATT_PERM_READ_AUTHEN | BT_GATT_PERM_READ_ENCRYPT,
NULL, NULL, NULL),
- BT_GATT_CCC(nus_ccc_cfg_changed, BT_GATT_PERM_READ | BT_GATT_PERM_WRITE),
+ BT_GATT_CCC(nus_ccc_cfg_changed, BT_GATT_PERM_READ_AUTHEN | BT_GATT_PERM_WRITE_AUTHEN | BT_GATT_PERM_READ_ENCRYPT | BT_GATT_PERM_WRITE_ENCRYPT),
BT_GATT_CHARACTERISTIC(BT_UUID_NUS_RX,
BT_GATT_CHRC_WRITE |
BT_GATT_CHRC_WRITE_WITHOUT_RESP,
- BT_GATT_PERM_READ | BT_GATT_PERM_WRITE,
+ BT_GATT_PERM_READ_AUTHEN | BT_GATT_PERM_WRITE_AUTHEN | BT_GATT_PERM_READ_ENCRYPT | BT_GATT_PERM_WRITE_ENCRYPT,
NULL, on_receive, NULL),
);&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Thanks for sharing the link with me! I will see and read your recommendation!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Use Peripheral and Central UART (NUS service) example with pairing</title><link>https://devzone.nordicsemi.com/thread/400401?ContentTypeID=1</link><pubDate>Tue, 13 Dec 2022 14:07:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f4cdfd6e-4ffb-48c1-8601-3f5f43b0bb04</guid><dc:creator>Sigurd Hellesvik</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Our &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.2.0/nrf/samples/bluetooth/peripheral_cgms/README.html"&gt;Bluetooth: Continuous Glucose Monitoring Service (CGMS) sample&lt;/a&gt; shows you how you can pair devices.&lt;/p&gt;
&lt;p&gt;Does this show you what you need?&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Sigurd Hellesvik&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>