<?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>Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/118957/title-distance-measurement-shows-double-the-actual-value-on-nrf52840</link><description>I am using an nRF52840 and nrf52832 to measure distance, but the reported value is almost twice the actual distance . For example, when the actual distance is 1 meter , the reading is around 2 meters . 
 What could be causing this issue? Is there a setting</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 05 Mar 2025 13:46:19 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/118957/title-distance-measurement-shows-double-the-actual-value-on-nrf52840" /><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/525998?ContentTypeID=1</link><pubDate>Wed, 05 Mar 2025 13:46:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:79ce1f63-4df0-4dd2-9da8-1a7965a78c29</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;What do you mean by &amp;quot;both antennas facing opposite to each other&amp;quot;? As in away from one another?&lt;/p&gt;
&lt;p&gt;Try putting the devices next to each other and see what the measured distance is then. That should give you less of a fluctuating distance and an idea of how much it should be calibrated with. With the 0.88-1.43m measurements it&amp;#39;s hard to say as I don&amp;#39;t know the median value or how often it reaches the minimum and maximum, but if it is an even spread/bell curve of measurements I guess the median value would be ~1.15m, meaning the calibration should be set to 0.55m so that the measurements will average ~60cm.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/525858?ContentTypeID=1</link><pubDate>Wed, 05 Mar 2025 04:41:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:23268015-72b4-459a-bf01-af43fb2c2a40</guid><dc:creator>Usha</dc:creator><description>&lt;div class="flex max-w-full flex-col flex-grow"&gt;
&lt;div dir="auto" data-message-author-role="assistant" data-message-id="ec49eb3c-a0ec-4a0b-9be6-f80302aeb488" data-message-model-slug="gpt-4o"&gt;
&lt;div&gt;
&lt;div class="markdown prose w-full break-words dark:prose-invert dark"&gt;
&lt;p data-start="0" data-end="92" data-is-last-node="" data-is-only-node=""&gt;&amp;quot;I am measuring in an office environment, with both antennas facing opposite to each other.&amp;quot;&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/525705?ContentTypeID=1</link><pubDate>Tue, 04 Mar 2025 12:28:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6d9eef48-e8e5-43a0-b864-065866132d58</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;It&amp;#39;s a bit strange that it fluctuates by this much. Are you testing on two nRF52 DKs or custom boards? And can you share some details on what environment you&amp;#39;re testing in? Are the devices in field of view of each other, and is there a lot of other activity on the 2.4GHz band in the space you&amp;#39;re testing here?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The zero distance calibration can also be done at 0cm, and the offset would be whatever the distance you see there that you will have to implement manually in your application so that the ranging result always adds/subtracts the offset before printing them to the terminal.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/525196?ContentTypeID=1</link><pubDate>Fri, 28 Feb 2025 06:34:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:018aa30a-3646-4e2f-8243-1cdb4e950eb4</guid><dc:creator>Usha</dc:creator><description>&lt;div class="content full threaded-reply-content user-defined-markup" data-replyid="525192" data-userid="138113" data-permalink="~/f/nordic-q-a/112159/the-zero-distance-calibration-of-ddfs/525192"&gt;
&lt;div class="content"&gt;
&lt;div class="flex max-w-full flex-col flex-grow"&gt;
&lt;div dir="auto" data-message-author-role="assistant" data-message-id="a8e081c4-6f88-4757-93f7-c2011f92625e" data-message-model-slug="gpt-4o"&gt;
&lt;div&gt;
&lt;div class="markdown prose w-full break-words dark:prose-invert dark"&gt;
&lt;p data-start="0" data-end="216" data-is-last-node="" data-is-only-node=""&gt;I am measuring the distance between two devices placed 60 cm apart, but the reported distance fluctuates between 0.88 m and 1.43 m. What could be causing this variation, and how can I accurately calibrate the offset?&lt;/p&gt;
&lt;p data-start="0" data-end="216" data-is-last-node="" data-is-only-node=""&gt;&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/523226?ContentTypeID=1</link><pubDate>Mon, 17 Feb 2025 10:49:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:677f8868-f6b6-469b-b3fa-520c1b03d495</guid><dc:creator>snoopy20</dc:creator><description>&lt;p&gt;Still pretty incredible that it can do that resolution. &lt;br /&gt;&lt;br /&gt;Then I started thinking how it would be done without a much higher clock and I thought if the receiver was able to echo the signal with a known latency then the required clock would be half and only one precision clock would be needed. Even so that&amp;#39;s still high but if there was multiple echoing each time would half the clock requirement at the expense of doubling the time needed to do the measurement.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/523056?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2025 13:13:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6fea5d69-5cec-42b3-be81-252715ba0186</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;So, while what Andrew is suggesting is correct, you should be able to get far better measurements than almost a 1 meter margin of error. I assume you&amp;#39;re using the Distance Measurement sample in the nRF Connect SDK for testing here. And the main issue when seeing large error margins here is that you need to do zero distance calibration, which is explained in the documentation of the sample here:&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/samples/bluetooth/nrf_dm/README.html#zero-distance_calibration"&gt;https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/samples/bluetooth/nrf_dm/README.html#zero-distance_calibration&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Additionally, right above it you can see a section on high precision calculations that is a config you can enable to increase the precision of your distance measurement.&lt;/p&gt;
&lt;p&gt;Lastly, as somewhat of a side note since the following is not supported on the nRF 52 series. On the nRF54L15, we have support for the new BLE distance measurement solution from the Bluetooth spec. called channel sounding. We have some experimental samples for that available as well here&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/samples/bluetooth/channel_sounding_ras_initiator/README.html"&gt;https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/samples/bluetooth/channel_sounding_ras_initiator/README.html&lt;/a&gt;, but it&amp;#39;s quite a bit to dig into, so I&amp;#39;d suggest starting out with the technical overview of the technology available here:&amp;nbsp;&lt;a href="https://www.bluetooth.com/channel-sounding-tech-overview/"&gt;https://www.bluetooth.com/channel-sounding-tech-overview/&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/523039?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2025 12:13:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:99a23530-93fb-484e-9136-8bc55b3a9ca7</guid><dc:creator>snoopy20</dc:creator><description>&lt;p&gt;Tape measure?&lt;br /&gt;&lt;br /&gt;No seriously I don&amp;#39;t know as it&amp;#39;s an area of BLE I&amp;#39;ve not focused on. What I will say is distance requires (I think) two synchronised time sources and a fast/high resolution timer needed to capture the time for the RF to travel the distance in question, in this case 1M.&lt;br /&gt;&lt;br /&gt;RF moves at the speed of light, 300,000km per second.&lt;br /&gt;&lt;br /&gt;So you need a resolution of 1/300^6. I&amp;#39;m impressed it can do 2M with only a 64MHz crystal. &lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/523037?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2025 12:06:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5c7b976b-c924-44cf-8525-ee9987d2662c</guid><dc:creator>Usha</dc:creator><description>&lt;p data-start="41" data-end="301"&gt;Thank you for your response regarding distance measurement. My actual device is placed at a distance of 1 meter, but the measured distance value is inaccurate. I would like to achieve more accurate distance measurements. What can I do to improve the accuracy?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Title: Distance Measurement Shows Double the Actual Value on nRF52840</title><link>https://devzone.nordicsemi.com/thread/523032?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2025 11:50:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b75ca73f-58ac-4f8c-87c8-b74f797a7cab</guid><dc:creator>snoopy20</dc:creator><description>&lt;p&gt;You might want to say something about how you are doing the measuring. My crystal ball is out of order at the moment.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>