This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Timer synchronous using Precision Time Protocol

Dear all,

I want to implement precision clock synchronisation between two Nordic NRF52840DK devices, I have seen the example using the Timeslot API with the Nordic SDK,but I want to implement

this with Precision Time Protocol,that is I need to retrieve timestamp or counter value at the point that a packet is actually sent or received at physical layer.

According to this post,It seems there are APIs in "Zephyr Bluetooth LE Controller" can do this.

But in my case,I use the LLPM example in nrf connect SDK,and this example only support SoftDevice controller.

Is there any similar APIs in SoftDevice Controller can achieve this? many thanks!!

Best regards.

   

Parents
  • Hello!

    Is this the example using the Timeslot API you're referring to?

    In case you weren't aware, there's also a newer Timeslot API for NCS, with a sample found here.

    The post you linked to doesn't seem to refer to an API, but suggests altering the Zephyr source code directly from what I can see.

    The SoftDevice controller is not open source, so that's not an option in this case.

    You'll have to talk with the Bluetooth controller either through Zephyr's Bluetooth Host API, or through nrfxlib's MPSL library.

    Best regards,

    Einar

  • Thanks for your kindly reply! The example you post is what I am referring to,In our use case,we want to calculate the packet latency from sender's application to receivers's application, so we retrieve time_stamp1 (t1) at app of sender and t2 at app of receiver. To get t2-t1 as transmission latency,the timer(or clock) at each side should be synchronized or in other word we need to know the offset of two timers.

    As a beginner, modifying the example using the Timeslot API for NCS is quite difficult for me,is there any sample code for NCS can approach this,I really need this,thanks a lot !!!!

    Best regards,

    hao

Reply
  • Thanks for your kindly reply! The example you post is what I am referring to,In our use case,we want to calculate the packet latency from sender's application to receivers's application, so we retrieve time_stamp1 (t1) at app of sender and t2 at app of receiver. To get t2-t1 as transmission latency,the timer(or clock) at each side should be synchronized or in other word we need to know the offset of two timers.

    As a beginner, modifying the example using the Timeslot API for NCS is quite difficult for me,is there any sample code for NCS can approach this,I really need this,thanks a lot !!!!

    Best regards,

    hao

Children
Related