User Tools

Site Tools


doc:lps:tdoa:protocol

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
doc:lps:tdoa:protocol [2017-12-18 15:08]
arnaud
doc:lps:tdoa:protocol [2020-05-12 14:02] (current)
kimberly
Line 1: Line 1:
 +<WRAP center round important 60%>
 +This page has deprecated and moved to the new documentation framework of the main Bitcraze website. Please go to [[https://www.bitcraze.io/documentation/system/]]
 +</WRAP>
 +
 +
 +
 ====== TDoA Anchor protocol V2 ====== ====== TDoA Anchor protocol V2 ======
  
Line 48: Line 54:
 ===== Calculating TDoA ===== ===== Calculating TDoA =====
  
-For an example of how to calculate TDoA of packets using this protocol you can look at the Crazyflie source code: https://github.com/bitcraze/crazyflie-firmware/blob/tdoa2/src/deck/drivers/src/lpsTdoaTag.c#L110. This section will explain in English and with drawing the theory used to calculate TDoA. +[[doc:lps:tdoa:principles|Please see TDoA positioning principles]]
- +
-If we consider the 3 last packets sent from anchor 0 and 1: +
- +
-{{:doc:lps:tdoa:tdoa-packets.png?600|}} +
- +
-We can calculate the difference of time of flight (which is the difference of time of arrival, TDoA) by calculating the diffence between δtx and δrx. From the tag side this can be done by receiving the last packet from each anchors:  +
-{{:doc:lps:tdoa:tdoa-to_tag.png?600|}} +
- +
-δrx is measured when receiving the two packets. δtx can be calculated in anchor 1 clock if we know the time it takes to fly from 0 to 1: Anchor 1 measures the time of arrival of the packet P2 and so knowing the time it took the packet to arrive to 1, we can calculate when it was sent by 0. +
- +
-The time of flight between 0 and 1 is measured by the anchors and transmitted in the packets. It is measured using two way ranging: +
-{{:doc:lps:tdoa:tdoa-anchors.png?600|}} +
- +
-Once we know the transmit time of P2 in the anchor 1, we can calculate δtx and δrx. Though δtx is expressed in the Anchor 1 clock. Each node have an imperfect clock and we need to compensate for drift between the clocks. To do so the tag uses two consecutive packet from Anchor 1 to keep track of the clock drift coefficient between its own clock and Anchor 1 clock: +
-{{:doc:lps:tdoa:tdoa-measure_drift.png?600|}} +
- +
-Using these two packet we can calculate α₁ = δrx1 / δtx1. We can now calculate TDoA = δrx - (α₁ * δtx). +
  
doc/lps/tdoa/protocol.1513606096.txt.gz · Last modified: 2017-12-18 15:08 by arnaud