<?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>The questions about NDT log</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/91523/the-questions-about-ndt-log</link><description>Hi Sir, 
 I am testing the NDT w/ example &amp;quot;nRF_DM&amp;quot; (NCS 2.0.0), there are two nRF52840-DK for this test. When two boards link success, the terminal starts to show the log. 
 I can see the value changed when the board moves to another way. From the log</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 18 Oct 2022 16:48:03 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/91523/the-questions-about-ndt-log" /><item><title>RE: The questions about NDT log</title><link>https://devzone.nordicsemi.com/thread/391280?ContentTypeID=1</link><pubDate>Tue, 18 Oct 2022 16:48:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ed9fdcbb-727e-451f-a5eb-8fec0a775c55</guid><dc:creator>Michal</dc:creator><description>&lt;p&gt;Hello Han,&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;1. Could you share the&amp;nbsp;experience, how to modify to support only advertising role or only scan role?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We only have a peer-to-peer sample currently, where all devices have both roles. Please check the &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.1.0/nrf/samples/bluetooth/nrf_dm/README.html#overview"&gt;sample documentation&lt;/a&gt; to read more about how it is implemented if you want to modify it heavily.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;span&gt;2. For the interval parameter, we can find the definition on gap.h.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;But how do we calculate&amp;nbsp;the value? like why 1.28s is &amp;quot;0x0800&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If we need to use other value, how to calculate?&lt;/span&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;span&gt;If you take a look in the &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.1.0/zephyr/connectivity/bluetooth/api/gap.html#c.BT_LE_SCAN_PARAM_INIT"&gt;GAP API documentation&lt;/a&gt; you can see that:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;_interval&lt;/strong&gt; – Scan Interval (N * 0.625 ms)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;_window&lt;/strong&gt; – Scan Window (N * 0.625 ms)&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Which means that N = 0x0800 = 2048 and that gives an interval of 2048 * 0.625 ms = 1280 ms = 1.28 s.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Michal&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;code&gt;&lt;span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The questions about NDT log</title><link>https://devzone.nordicsemi.com/thread/390874?ContentTypeID=1</link><pubDate>Sun, 16 Oct 2022 13:10:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:621e6b2c-eda3-4dd9-8caf-2e51c28f9f84</guid><dc:creator>Hsu</dc:creator><description>&lt;p&gt;Hi Michal,&lt;/p&gt;
&lt;p&gt;Sorry to late response.&lt;/p&gt;
&lt;p&gt;I tried to modify the code to support one device support one role (advertising or scan).&lt;/p&gt;
&lt;p&gt;I modified the &amp;quot;&lt;span&gt;bt_sync_init&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;void&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&amp;quot;, for support advertising role, I comment out the &amp;quot;&lt;span&gt;scan_start&lt;/span&gt;&lt;span&gt;()&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Also, for support scan role, I comment out the &amp;quot;&lt;/span&gt;adv_start();&lt;span&gt;&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;But the result is they can boot up success but cannot get link success.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;1. Could you share the&amp;nbsp;experience, how to modify to support only advertising role or only scan role?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&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/pastedimage1665925348902v1.png" alt=" " /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;2. For the interval parameter, we can find the definition on gap.h.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;But how do we calculate&amp;nbsp;the value? like why 1.28s is &amp;quot;0x0800&amp;quot;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If we need to use other value, how to calculate?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="zh-TW"&gt;#define&lt;/span&gt;&lt;span lang="en-US"&gt; BT_GAP_SCAN_SLOW_INTERVAL_1 &lt;/span&gt;&lt;span lang="en-US"&gt;0x0800&lt;/span&gt;&lt;span lang="en-US"&gt; /* 1.28 s */&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="zh-TW"&gt;#define&lt;/span&gt;&lt;span lang="en-US"&gt; BT_GAP_SCAN_SLOW_WINDOW_1 &lt;/span&gt;&lt;span lang="en-US"&gt;0x0012&lt;/span&gt;&lt;span lang="en-US"&gt; /* 11.25 ms */&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="zh-TW"&gt;#define&lt;/span&gt;&lt;span lang="en-US"&gt; BT_GAP_ADV_FAST_INT_MIN_2 &lt;/span&gt;&lt;span lang="en-US"&gt;0x00a0&lt;/span&gt;&lt;span lang="en-US"&gt; /* 100 ms */&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="zh-TW"&gt;#define&lt;/span&gt;&lt;span lang="en-US"&gt; BT_GAP_ADV_FAST_INT_MAX_2 &lt;/span&gt;&lt;span lang="en-US"&gt;0x00f0&lt;/span&gt;&lt;span lang="en-US"&gt; /* 150 ms */&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="en-US"&gt;Thank you.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span lang="en-US"&gt;BRs, Han&lt;/span&gt;&lt;/p&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: The questions about NDT log</title><link>https://devzone.nordicsemi.com/thread/384424?ContentTypeID=1</link><pubDate>Fri, 02 Sep 2022 13:24:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1852c394-7db6-4559-83b2-c20477150686</guid><dc:creator>Michal</dc:creator><description>&lt;p&gt;Hello Hanyu,&lt;/p&gt;
&lt;p&gt;best=0.17 means that the distance is 0.17 m, or 17 cm.&lt;/p&gt;
&lt;p&gt;Yes, multi-link is supported. You can find a &lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/main/samples/bluetooth/nrf_dm/src/peer.c#L14"&gt;PEER_MAX macro&lt;/a&gt; in the peer.c file in the nrf_dm sample. You can distinguish between the devices by their address.&lt;/p&gt;
&lt;p&gt;Indoor positioning should definitely be possible with some triangulation.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Michal&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The questions about NDT log</title><link>https://devzone.nordicsemi.com/thread/384361?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 14:16:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:af276f71-81a5-44f1-b5e0-bb975fa17562</guid><dc:creator>Hsu</dc:creator><description>&lt;p&gt;Hi Michal,&lt;/p&gt;
&lt;p&gt;Thanks for the quick update.&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If the easiest way is just to use&amp;nbsp;the &amp;quot;best&amp;quot;,&amp;nbsp;&amp;nbsp;Does the &amp;quot;&lt;span style="color:#ff0000;"&gt;&lt;strong&gt;best=0.17&lt;/strong&gt;&lt;/span&gt;&amp;quot; mean the distance is .017 m?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Further questions,&lt;/p&gt;
&lt;p&gt;- Can the DM central role support multi-link natively?&lt;/p&gt;
&lt;p&gt;- If the above function works, could we use DM for indoor positioning? Like if&amp;nbsp;we put 3+ DM-peripheral into fixed positions and DM central role uses these DM-peripherals to know the position of DM central role?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thank you.&lt;/p&gt;
&lt;p&gt;BRs, Hanyu&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: The questions about NDT log</title><link>https://devzone.nordicsemi.com/thread/384313?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 11:32:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:efd586f8-62ba-4475-88ed-51658fe163f7</guid><dc:creator>Michal</dc:creator><description>&lt;p&gt;Hello Han,&lt;/p&gt;
&lt;p&gt;Those parameters are just distance measurement estimates using three different methods. The unit is meters.&lt;/p&gt;
&lt;p&gt;From the &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.0.2/nrfxlib/nrf_dm/doc/nrf_dm_overview.html#overview"&gt;documentation&lt;/a&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Multi-carrier phase difference:&lt;/p&gt;
&lt;blockquote&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;IFFT of spectrum&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Average phase-slope estimation&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Friis-path-loss formula&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;/blockquote&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;The easiest way would be to just use the &amp;quot;best&amp;quot; estimation value.&lt;/p&gt;
&lt;p&gt;There is also a &lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.0.2/nrfxlib/nrf_dm/doc/api.html#c.nrf_dm_high_precision_calc"&gt;nrf_dm_high_precision_calc()&lt;/a&gt; function that uses a much more complicated algorithm and takes a much longer time to execute. It also just returns a float, instead of filling out the whole struct with data.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Michal&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>