Openthread network synchronisation

31 views Asked by At

I'm in the process of setting up an OpenThread network of 20 nodes that need to be synchronised to within 200us for sophisticated power measurements. I'm using the EFR32xG24 Explorer Kit for this project. After evaluating various wireless protocols for my chip, I found that OpenThread would provide the most effective solution. While researching synchronisation, I found papers discussing the accuracy of wireless synchronisation, although none specifically addressed large networks. In my existing OpenThread network, one device acts as the central synchronisation coordinator, while the others act as peripherals. The OpenThread network works, but I have problems with the accuracy of the synchronisation.

To achieve synchronisation, I've explored two approaches:

  1. The central device has a counter with an accuracy of 6us and all the peripherals have the same timer. The central unit transmits its timer counter every 200ms. The peripherals receive and store these values and simultaneously store their own timer counts. The peripherals then calculate the differences between these timer counts. This is averaged over 50 instances. This averaged difference is then added to the individual timer counts of the peripherals to synchronise them with all other devices. Currently I'm getting an accuracy of about 400us when using the timer interrupt to toggle a pin. I am measuring this on all devices to compare delays. Unfortunately, I'm not sure of the source of this inaccuracy. The time it takes to read the timer count on the central device compared to the peripheral device ranges from 10ms to 14ms. The devices receive the broadcast at exactly the same time.
  2. OpenThread includes a timestamp that can be synchronised and read using the Network Time Synchronisation add-on. I believe it offers 1us accuracy at 300ppm, but I couldn't find any detailed information on this. I initialise time synchronisation on all devices, allowing them to synchronise at intervals of between 1s and 40s. The synchronised time is then read and stored in a timer counter, which is essential for coordinating my network using timer-based interrupts. With this approach I've achieved an accuracy of around 200us when using the timer interrupt to toggle a pin, measuring this on all devices and comparing the delay.

I'm looking for advice on how to identify the source of inaccuracy in my synchronization and how to eliminate it to ensure the highest possible accuracy. Any insight would be greatly appreciated.

0

There are 0 answers