<?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 Force LE Coded PHY S=8 (125 kbps) for Extended Advertising on nRF52840 with Zephyr/nRF Connect SDK?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/121377/how-to-force-le-coded-phy-s-8-125-kbps-for-extended-advertising-on-nrf52840-with-zephyr-nrf-connect-sdk</link><description>Hi all, 
 I&amp;#39;m working on a project with an nRF52840 using the nRF Connect SDK (version X.Y.Z) and Zephyr RTOS. My goal is to achieve maximum possible range for non-connectable extended advertising, so I&amp;#39;m trying to use LE Coded PHY S=8 (125 kbps) . 
</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 13 May 2025 16:57:54 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/121377/how-to-force-le-coded-phy-s-8-125-kbps-for-extended-advertising-on-nrf52840-with-zephyr-nrf-connect-sdk" /><item><title>RE: How to Force LE Coded PHY S=8 (125 kbps) for Extended Advertising on nRF52840 with Zephyr/nRF Connect SDK?</title><link>https://devzone.nordicsemi.com/thread/535187?ContentTypeID=1</link><pubDate>Tue, 13 May 2025 16:57:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:62d8c918-4b13-45be-8087-e2b194a7ae67</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;While the HCI command encode the PHY as you said, the host converted it to a different encoding scheme. Please refer to:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/nrfconnect/sdk-zephyr/blob/v4.0.99-ncs1/subsys/bluetooth/host/scan.c#L744-L764"&gt;https://github.com/nrfconnect/sdk-zephyr/blob/v4.0.99-ncs1/subsys/bluetooth/host/scan.c#L744-L764&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;If you want to confirm that is actually the case, here is the traceback:&lt;/p&gt;
&lt;p&gt;In nrf/subsys/bluetooth/scan.c:&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;notify_filter_no_match()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;filter_state_check()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;&amp;gt;scan_recv&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;&amp;gt;&amp;gt;struct bt_le_scan_cb .recv&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;In zephyr/subsys/bluetooth/host/scan.c&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;listener-&amp;gt;recv&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;le_adv_recv()&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;&amp;gt;bt_hci_le_adv_ext_report(), where&amp;nbsp;create_ext_adv_info() is used to prepare the scan report&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:&amp;#39;courier new&amp;#39;, courier;"&gt;&amp;gt;&amp;gt;&amp;gt;get_ext_adv_coding_sel_phy()&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to Force LE Coded PHY S=8 (125 kbps) for Extended Advertising on nRF52840 with Zephyr/nRF Connect SDK?</title><link>https://devzone.nordicsemi.com/thread/534912?ContentTypeID=1</link><pubDate>Mon, 12 May 2025 13:24:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:617ffebe-dbbc-4c4b-a5af-7c72c3892243</guid><dc:creator>Lorenz242</dc:creator><description>&lt;p class="ng-star-inserted"&gt;&lt;span class="ng-star-inserted"&gt;I&amp;#39;m getting the PHY values from the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;primary_phy&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;and&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;secondary_phy&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;members of&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;device_info-&amp;gt;recv_info&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;(which is a&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;const struct bt_le_scan_recv_info *&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;) within the&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;filter_no_match&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;callback of the Nordic&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;nrf_bt_scan&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;API (using&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;#include &amp;lt;bluetooth/scan.h&amp;gt;&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;).&lt;/span&gt;&lt;/p&gt;
&lt;p class="ng-star-inserted"&gt;&lt;pre class="ui-code" data-mode="text"&gt;// From the scan_filter_no_match_cb:
// struct bt_scan_device_info *device_info;
// ...
if (gps_data_deserialize_from_adv(manuf_data_ptr, manuf_data_len,
                                  &amp;amp;received_manuf_id, &amp;amp;received_gps_data)) {
    if (received_manuf_id == GPS_TRACKER_MANUFACTURER_ID) {
        LOG_INF(&amp;quot;GPS-Tag gefunden: %s, RSSI: %d dBm, PHY: Prim %u, Sec %u, TX-Power: %d dBm&amp;quot;,
                addr_str,
                device_info-&amp;gt;recv_info-&amp;gt;rssi,
                device_info-&amp;gt;recv_info-&amp;gt;primary_phy, // This is what I&amp;#39;m logging as &amp;quot;Prim&amp;quot;
                device_info-&amp;gt;recv_info-&amp;gt;secondary_phy, // This is what I&amp;#39;m logging as &amp;quot;Sec&amp;quot;
                device_info-&amp;gt;recv_info-&amp;gt;tx_power);
    }
}&lt;/pre&gt;&lt;/p&gt;
&lt;p class="ng-star-inserted"&gt;&lt;span class="ng-star-inserted"&gt;My interpretation of the logged&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;4&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;as S=2 (and&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="inline-code ng-star-inserted"&gt;3&lt;/span&gt;&lt;span class="ng-star-inserted"&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;as S=8) is based on the Bluetooth Core Spec (v6.1, page&amp;nbsp;2357/ 2358)&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to Force LE Coded PHY S=8 (125 kbps) for Extended Advertising on nRF52840 with Zephyr/nRF Connect SDK?</title><link>https://devzone.nordicsemi.com/thread/534877?ContentTypeID=1</link><pubDate>Mon, 12 May 2025 12:14:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9310d9ba-e2ff-4393-a4b4-0ced348acca0</guid><dc:creator>Hieu</dc:creator><description>&lt;p&gt;Hi Lorenz242,&lt;/p&gt;
&lt;p&gt;Which function are you using to extract the PHY value?&amp;nbsp;A value of 4 doesn&amp;#39;t necessarily mean&amp;nbsp;S=2.&amp;nbsp;For example, here it means&amp;nbsp;Coded PHY&amp;nbsp;with unspecified encoding:&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-zephyr/blob/v4.0.99-ncs1-1/include/zephyr/bluetooth/gap.h#L743-L760"&gt;sdk-zephyr/include/zephyr/bluetooth/gap.h at v4.0.99-ncs1-1 · nrfconnect/sdk-zephyr&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Hieu&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>