MIMXRT1062: Where does the PTP timestamp come from in "slave mode"?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

MIMXRT1062: Where does the PTP timestamp come from in "slave mode"?

846件の閲覧回数
MultipleMonomials
Contributor IV

Hello!  I have a question about synchronizing together the timestamps recorded by the two ETH MACs on the MIMXRT1062.  The reference manual says this:

MultipleMonomials_0-1688427790694.png

If I find the ATCR.SLAVE bit description, it doesn't really provide any more information:

MultipleMonomials_1-1688427839465.png

Neither of these say what the "externally provided time source" is when "slave mode" is enabled.  I searched the rest of the ENET chapter as well, and wasn't able to find any info.  Is the source the other ethernet MAC?  Is there any other configuration needed to set up time from one MAC to be used by the other MAC?

I'd really appreciate if someone could look into this.  Thank you!

ラベル(1)
タグ(2)
0 件の賞賛
返信
3 返答(返信)

810件の閲覧回数
EdwinHz
NXP TechSupport
NXP TechSupport

Hi @MultipleMonomials,

I believe you are referring to the "External free-running counter" from Figure 41-10 of the RT1060 Reference Manual:

EdwinHz_0-1688599521938.png

I invite you to look into the following community post, since it describes in much more detail the usage and functionality of the external FRC: https://community.nxp.com/t5/i-MX-RT/Can-the-FRC-in-the-ENET-block-be-clocked-from-an-external/m-p/1...

BR,
Edwin.

0 件の賞賛
返信

604件の閲覧回数
MultipleMonomials
Contributor IV

I know it's been a while, but I finally got a chance to test this out on hardware.  In case anyone else finds this, I can confirm that the "External Free-Running Counter" is in fact the other ethernet MAC on dual-Ethernet devices.  So, if you are using two Ethernet ports and want them to share their PTP time, you just need to:

  1. Initialize the ENET1 PTP time like normal
  2. Set the ATCR.SLAVE bit in the ENET2 registers (you don't need to do any other initialization for ENET2)
  3. ENET2's PTP time is now the same as ENET1.

I have checked that capturing works, e.g. I can do an input capture from an event in pin on ENET2 and the capture registers save the time from ENET1.  I haven't checked anything else yet but based on the diagram I assume that all of the timing-related features for ENET2 work correctly when getting the time from ENET1.

0 件の賞賛
返信

804件の閲覧回数
MultipleMonomials
Contributor IV

Hi Edwin!

That's correct, I'm referring to the "external free-running counter" in that diagram.  What I'm trying to figure out is, where does that counter value come from?  What's the source of that arrow?  The term "external free-running counter" doesn't seem to appear anywhere else in the datasheet, and searches for that name come up empty.

I checked the thread you linked, and also the thread linked there.  But, sadly, neither of those threads mentions what the source of the external free-running counter is.  So, I'm still not sure where that arrow comes from.  I'd really appreciate if you could look into this!

Thanks,
Jamie

 

0 件の賞賛
返信