<?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>Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/113679/bluetooth-5-4-on-nordic-platform</link><description>Hi. I have some question regarding to Bluetooth 5.4 on Nordic platform 
 
 1. Can Nordic platform do Advertising Coding Selection? I saw some old old issue that the device can only transmit with S=8 when using the LE Coded PHY. 
 
 2. Is there an article</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 09 Aug 2024 09:20:42 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/113679/bluetooth-5-4-on-nordic-platform" /><item><title>RE: Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/thread/497593?ContentTypeID=1</link><pubDate>Fri, 09 Aug 2024 09:20:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1ba8b2f5-a79d-4a75-90af-6837d65494f6</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;glad that the reply helped. Can yo uplease mark my reply as verified answer so that it could help other forum members?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/thread/497498?ContentTypeID=1</link><pubDate>Thu, 08 Aug 2024 14:07:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:125735c2-66e0-416d-ae69-af8f1093f9dc</guid><dc:creator>Tony Cheng</dc:creator><description>&lt;p&gt;Thank you so much. Susheel.&lt;/p&gt;
&lt;p&gt;You saved my day.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/thread/497409?ContentTypeID=1</link><pubDate>Thu, 08 Aug 2024 05:49:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2324786f-b0e0-4fc4-b064-b30b2d6453e2</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Tony,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;sorry was away half of the day yesterday.&lt;/p&gt;
[quote user="Tony Cheng"]May I ask&amp;nbsp;&lt;span&gt;how to choose to advertise in S=2 or S=8 with LE coded PHY?&lt;/span&gt;[/quote]
&lt;p&gt;Something like below maybe in the connected callback or wherever it seems fit in your application.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;param.options = BT_CONN_LE_PHY_OPT_CODED_S2;
param.pref_tx_phy = BT_HCI_LE_PHY_CODED;
param.pref_rx_phy = BT_HCI_LE_PHY_CODED;

err = bt_conn_le_phy_update(conn, &amp;amp;param);
if (err) {
    printk(&amp;quot;Update PHY error: %d\n&amp;quot;, err);
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote user="Tony Cheng"]Also, how&amp;nbsp;to add a characteristic to the GAP service? I am trying to create the&amp;nbsp;security level&amp;nbsp;characteristic.[/quote]
&lt;p&gt;Please do not mix many questions in one into a thread. This one is a basic question that has been asked before. But let me try to explain this one.&lt;/p&gt;
&lt;p&gt;&lt;span&gt;You can add a characteristic with security to a service by defining the characteristic and its properties, and then adding it to the service. Here&amp;#39;s a general example of how to do it:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="text"&gt;#include &amp;lt;bluetooth/gatt.h&amp;gt;

/* GATT service declaration */
BT_GATT_SERVICE_DEFINE(my_service,
    BT_GATT_PRIMARY_SERVICE(&amp;amp;my_service_uuid),
    BT_GATT_CHARACTERISTIC(&amp;amp;my_char_uuid.uuid, &amp;amp;my_char_props,
                           BT_GATT_PERM_READ_AUTHEN,
                           read_callback, write_callback, &amp;amp;my_value),
    ...
);&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;code dir="ltr"&gt;BT_GATT_SERVICE_DEFINE&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;is a macro that defines a GATT service.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PRIMARY_SERVICE&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;is a macro that defines a primary service.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_CHARACTERISTIC&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;is a macro that defines a characteristic.&lt;/p&gt;
&lt;div&gt;&lt;code dir="ltr"&gt;my_service_uuid&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;and&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;my_char_uuid&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;are the UUIDs of the service and the characteristic, respectively.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;my_char_props&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;are the properties of the characteristic.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PERM_READ_AUTHEN&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;is the permission for the characteristic, which requires authentication for read access.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;read_callback&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;and&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;write_callback&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;are the read and write callbacks for the characteristic.&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;my_value&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;is the initial value of the characteristic.&lt;/div&gt;
&lt;div&gt;Please note that the actual code may vary depending on your application requirements and the version of Zephyr you are using.&lt;/div&gt;
&lt;div&gt;For more information, you can refer to the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://docs.zephyrproject.org/latest/reference/bluetooth/gatt.html" rel="noopener noreferrer" target="_blank"&gt;Zephyr documentation&lt;/a&gt;.&lt;/div&gt;
&lt;div&gt;For adding a characteristic with a specific security level, you can set the permissions of the characteristic to&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PERM_READ_ENCRYPT&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;or&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PERM_READ_AUTHEN&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;for read access, and&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PERM_WRITE_ENCRYPT&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;or&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;code dir="ltr"&gt;BT_GATT_PERM_WRITE_AUTHEN&lt;/code&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;for write access. These permissions require encryption or authentication for read or write access, respectively.&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;Also check if these pages on Security is of some help.&lt;/div&gt;
&lt;div&gt;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/zephyr/security/secure-coding.html" rel="noopener noreferrer" target="_blank"&gt;Zephyr &amp;gt; Security &amp;gt; Secure Coding&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/zephyr/security/security-overview.html" rel="noopener noreferrer" target="_blank"&gt;Zephyr &amp;gt; Security &amp;gt; Zephyr Security Overview&lt;/a&gt;&lt;/div&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/thread/497132?ContentTypeID=1</link><pubDate>Tue, 06 Aug 2024 11:02:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a00833a1-7c87-4b22-a617-b39149cc00f0</guid><dc:creator>Tony Cheng</dc:creator><description>&lt;p&gt;Thanks for the quick response. Susheel. It helps a lot.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;May I ask&amp;nbsp;&lt;span&gt;how to choose to advertise in S=2 or S=8 with LE coded PHY?&lt;/span&gt;&lt;/p&gt;
&lt;div&gt;&lt;/div&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Also, how&amp;nbsp;to add a characteristic to the GAP service? I am trying to create the&amp;nbsp;security level&amp;nbsp;characteristic.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1722940469778v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;I am using the SDK v2.7.0.&lt;/p&gt;
&lt;p&gt;Thank you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Bluetooth 5.4 on Nordic platform</title><link>https://devzone.nordicsemi.com/thread/497099?ContentTypeID=1</link><pubDate>Tue, 06 Aug 2024 08:12:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c5793955-4d33-4bde-8ae9-a81b354b726a</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user=""]1. Can &lt;span&gt;Nordic platform&amp;nbsp;&lt;/span&gt;do Advertising Coding Selection? I saw some old old issue that the device can only transmit with S=8 when using the LE Coded PHY.&amp;nbsp;&amp;nbsp;[/quote]
&lt;p&gt;S=8 and S=2 works on our latest nRF Connect SDK latest versions.&lt;/p&gt;
[quote user=""]2. Is there an article summarized the compatibility of&amp;nbsp;&lt;span&gt;Nordic devices with&amp;nbsp;Bluetooth 5.0,&amp;nbsp;Bluetooth 5.1,&amp;nbsp;Bluetooth 5.2,&amp;nbsp;Bluetooth 5.3,&amp;nbsp;Bluetooth 5.4?&amp;nbsp;&lt;/span&gt;[/quote]
&lt;p&gt;Nordic is compatible and implements all the features required by BLE new versions. We do not have a compatibility and comparison matrix by itself, but there are many external blogs summarizing this. For example &lt;a href="https://www.mokosmart.com/guide-on-different-bluetooth-versions/"&gt;this &lt;/a&gt;one. If you want to know any compatibility of any specific feature in a specific version of BLE with nRF devices, then please be specific and we can try to find the relevant info.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>