This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM3358: PTP how to demo using clock out??

Part Number: AM3358
Other Parts Discussed in Thread: AM5708

Tool/software: Linux

What I like to do is demo the PTP by connecting an output from the master beaglebone black and an output from the slave beaglebone and put them on a scope and show that they are synched? How can that be done? 

Also in the PTP presentation it does not say what clock is synced to the master? is it an internal clock or just some timer? Any details would help a bunch.

Thanks

  • Mohsen,

    Thanks so much for your post. I wanted to make sure you've seen our detailed documentation here:

    software-dl.ti.com/.../Industrial_Protocols_PTP.html

    I believe this will answer your questions above and provide the information you need to do the demo. Please let us know if you have further specific questions after you've had a chance to review this.

    Thanks and I hope this is helpful to you.
  • Hi Ron
    thanks for the reply, i have been reading the app note but it seems that the test setup is done with the AM57x versus the AM335? have we done this with AM335 also?
    It also looks like the PRU is involved in this as well. Can you specify what is the PRU doing in this case.

    Thanks
  • Hi Ron
    couple of more questions,

    1) what PLL inside the device (AM335x) is being changed by the PTP software.?
    2) Can these changes be applied to the AUXCLK clock?
    3) Can we use the CPSW on the AM335 or we have to use the PRU MAC?
    4)We need a 1G etherent port sounds like we have to sue the AM5708 device.
    5)On the site you send me there are scope plots but it does not look like a clock, it is just a pulse? can you explain them a little more?
    6) What is the timer6 and timer5 are used for?
  • Mohsen Khayami said:
    thanks for the reply, i have been reading the app note but it seems that the test setup is done with the AM57x versus the AM335? have we done this with AM335 also?

    We've done it with both, using PRU ports for Ethernet.

    Mohsen Khayami said:
    t also looks like the PRU is involved in this as well. Can you specify what is the PRU doing in this case.

    Yes, in the documentation, most of the time we are referring to PRU ports using the IEP timer for PTP. It can also be done with the CPSW (needed for Gigabit) and the CPTS as the clock. I'm checking on the 1PPS output using CPSW/CPTS as I don't believe it is available yet.

  • Mohsen Khayami said:
    1) what PLL inside the device (AM335x) is being changed by the PTP software.?

    It is not a PLL, but an incrementing timer. The CPTS is used with CPSW and the IEP is used with the PRU.

    Mohsen Khayami said:
    2) Can these changes be applied to the AUXCLK clock?

    I don't believe so.

    Mohsen Khayami said:
    3) Can we use the CPSW on the AM335 or we have to use the PRU MAC?

    The 1PPS output is only available at this time with the PRU. PTP works with either.

    Mohsen Khayami said:
    4)We need a 1G etherent port sounds like we have to sue the AM5708 device.

    AM335x/AM437x CPSW would provide the 1G output, but the 1PPS is not available quite yet.

    Mohsen Khayami said:
    5)On the site you send me there are scope plots but it does not look like a clock, it is just a pulse? can you explain them a little more?

    These are the 1PPS signals from the Master and Slave being compared.

    6) What is the timer6 and timer5 are used for?

    For synchronizing the Boundary Clock in the AM57x example. It is is the only device that support BC.

    I hope this helps.

  • In reply to Mohsen Khayami:

    Mohsen Khayami
    1) what PLL inside the device (AM335x) is being changed by the PTP software.?
    Ron
    It is not a PLL, but an incrementing timer. The CPTS is used with CPSW and the IEP is used with the PRU.
    Mohsen
    Something does not make sense how can we match the clock from the master to the slave? With the timer i guess you can get a pulse but you are not synching the clock from the master to the slave? So how can the system clock from the master be synched to the system clock on the slave?

    Mohsen Khayami
    2) Can these changes be applied to the AUXCLK clock?
    I don't believe so.

    Mohsen Khayami
    3) Can we use the CPSW on the AM335 or we have to use the PRU MAC?
    The 1PPS output is only available at this time with the PRU. PTP works with either.

    Mohsen Khayami
    4)We need a 1G etherent port sounds like we have to sue the AM5708 device.
    AM335x/AM437x CPSW would provide the 1G output, but the 1PPS is not available quite yet.

    Mohsen Khayami
    5)On the site you send me there are scope plots but it does not look like a clock, it is just a pulse? can you explain them a little more?
    These are the 1PPS signals from the Master and Slave being compared.
    Mohsen
    The 1PPS is coming from the timer and it is just a pulse. So in reality we are not synching the clock from the master to the slave? Or are we using that pulse to synch the master to the slave some how?

    6) What is the timer6 and timer5 are used for?

    For synchronizing the Boundary Clock in the AM57x example. It is is the only device that support BC.

    Mohsen
    what I need is to have the clock synch from the master to the slave. Not just having a pulse. I wonder if i can use that pulse to trigger a clock to synch on the salve? not sure how to do this but need some help here.

    Thanks
  • Mohsen Khayami said:
    Something does not make sense how can we match the clock from the master to the slave? With the timer i guess you can get a pulse but you are not synching the clock from the master to the slave? So how can the system clock from the master be synched to the system clock on the slave?

    We need to be more specific about "clocks". There are many "clocks" and timers in a system. What are you referring to as "system clock"? To me, this is the clock driviing the device, something like a 20MHz oscillator. This is hardware. "SystemTime" is some interpretation of this clock managed by software. But even then, there are usually lots of timebases in a complex system.

    Linux uses a variety of open source software to manage PTP, which synchronizes two clocks, a Master and a Slave. There is other software to merge these clocks into sytem time.

    This is illustrated pretty well starting at 10:04 of this presentation:

    https://training.ti.com/ptp-procsdk-linux-ptp-on-linux?cu=1136194

    Mohsen Khayami said:
    The 1PPS is coming from the timer and it is just a pulse. So in reality we are not synching the clock from the master to the slave? Or are we using that pulse to synch the master to the slave some how?

    In this case, the 1PPS is used to validate synchronization. However, a 1PPs signal can be used to synchronize clocks as well, but it takes an additional wire and cabling, thus something like PTP is preferred.

    Mohsen Khayami said:
    what I need is to have the clock synch from the master to the slave. Not just having a pulse. I wonder if i can use that pulse to trigger a clock to synch on the salve? not sure how to do this but need some help here.

    I think the rest of the training above will clarify this. The Linux package ptp4l will work with the CPTS or the IEP to synchronize across Ethernet using PTP. The PTP protocol is further outlined in the training above.

    I hope this helps you.