i.MX6s/dl: input PPS to FEC for PTP Grand master ENET_1588_EVENT0_IN

Showing results for 
Show  only  | Search instead for 
Did you mean: 

i.MX6s/dl: input PPS to FEC for PTP Grand master ENET_1588_EVENT0_IN

Contributor I

I am currently looking at implementing PTP on our device to function as grandmaster.

We can achieve some decent results with a seperate GNSS module providing reference time and 1-PPS signal hooked to a GPIO.

To achieve better results (<1usec accuracy) it is ideal to connect the 1-PPS signal directly to the FEC via one of the IEEE 1588 4 channel's ENET_1588_EVENT<0-3>_IN pins. (These are muxed with various GPIOpins).

An example of a NIC that supports such behavior is the Intel i210.

Looking at the fec_ptp.c driver it does not currently support any INPUT PPS to control the phc in the fec.

Is there any word on support for this coming soon?

I appreciate any help on this subject.



ptp‌ fec pps ethernet driver 

Labels (4)
3 Replies

NXP Employee
NXP Employee

GPIO capture PPS is not accuracy since system irq latency is us level.

ptp event capture PPS is accuracy since HW capture ptp timer in register/memory, it is not impacted by irq latency.

=> So you can use ptp event capture PPS.

The second step is imx ptp master(ordinary clock) should sync to GPS PPS.

Suppose imx ptp clock source is not GPS output,  so it request software to do frequently correction for ptp clock based on PPS interval.

=> So you should implement one arithmetic to do rate correction for ptp clock.

The last, ptp slave sync with imx ptp master(ordinary clock), then ptp slave device PPS output should sync with GPS PPS.

NXP Employee
NXP Employee

Yes, BSP doesn't support input PPS.  But it support output 1PPS.

For your case:

1PPS -> imx GPIO,  then imx capture the 1PPS timer

imx ptp master clock second sync to 1PPS timer

 imx as ordinary clock -> ptp slave sync to imx ordinary clock

Contributor III

Andy Duan ha scritto:

Yes, BSP doesn't support input PPS.

Is this still the case with latest 5.4.x BSP in 2020?

Thank you

0 Kudos