Source code for TDOA

Hello. can someone share the source code for the TDA system? Interested in a method of calculating coordinates, wired or wireless synchronization. The distance between the anchors is 5 meters. I guarantee gratitude.

Hello Arthur,

Decawave has a solution for TDoA with DW1000 – It is the TTK1000 kit. The software source code is not opened, the customer must get a license to access it.

Please see TTK1000 - DW1000 based TDoA Toolkit for further information.

Hope it helps,
Thnaks
Yves

If you want full source code for a simple distance measurement, take a look at

Iosoft UWB blog

1 Like

So does no open-sourced code exist for basic TDoA elements? Only TWR?

No one on the Internet has open sourced the code of tdoa.
But I wrote several articles introducing how to implement your own tdoa uwb location system. I introduced how to solve some difficulties in tdoa technology. If you are willing to spend time, you can implement your own location system based on tdoa.

Hello. Is it available now? I seriously searched online and still couldn’t find it. I wonder if anyone has found it?

The answer is still no, you need to make your own.

TDoA requires very tightly synchronised timing on the beacons. This normally involved special hardware with dedicated time sync signals being passed to all beacons. If you need custom hardware then an open source solution isn’t much help unless they also open source the hardware designs. But even then manufacturing a board with the DW1000 IC rather than a module (as required for hardware time sync) is not trivial.
It is possible to do this without special hardware but the firmware to obtain the required time synchronisation is not trivial. For TWR you can skip all the little details that give better results and still get a fairly good solution making it simple to get a system that’s good enough a lot of the time. With TDoA if you don’t get the details correct and all the different compensation factors included you get junk. Generally anyone who is going to take the time to do that well is going to be doing it as a commercial project and so won’t be open sourcing it.

Thank you for your reply. What library did you use for TWR? When I looked at the libraries on GitHub, the system does not work for multiple tags and starts to choke.

I didn’t use any library, I created my own.

Just about all the examples on the net seem to be based on some old decawave example code. This was apparently written by someone who had never heard of a packed struct and so used a byte array for putting the message together.
I suspect it was originally intended purely as a proof of concept and means of testing the hardware rather than as a real world system implementation. Unfortunately most of the open source code out there seem to have taken this proof of concept code and make the minimal (if any) changes needed to make things work for their hardware.

The changes for multiple tags/anchors aren’t too complex:
Give each unit a unique ID number.
Change the message structure to include To and From ID fields (technically only one is needed but both gives more flexibility).
On message reception if the To field doesn’t match your ID then ignore it. Either go to idle or back to receive mode depending on how your system works.