Ethernet Design Example Components User Guide

ID 683044
Date 9/27/2021
Public

A newer version of this document is available. Customers should click here to go to the newest version.

1.4.1. Adjusting TOD Drift

You can use the DriftAdjust and DriftAdjustRate registers to correct drifts in the TOD clock due to insufficient binary representation of the 16-bit fractional nanosecond field in the Period register.

For example, the Period register is set to 6.4 ns for a 10G Ethernet application. The hexadecimal representation of this value is 0x6 ns and 0x6666.4 fns.
  • Fractional nanosecond field is 16 bits wide: 0.4 fns = 0.4 * 216 = 26214.4 in decimal.
  • Converting to hexadecimal: 26214 + 0.4 = 0x6666 + 0x0000.4 = 0x6666.4 fns.
The fractional nanosecond value, 0x0000.4, cannot be represented in 16 bits thus causing the time of day to drift from the actual time by 0x0002 fns every 5 clock cycles. In other words, the time of day drifts 953.6 ns every 1 second. To correct this situation, configure the registers as follow:
  • DriftAdjust = 0x02, which sets the nanosecond field to 0x0 and the fractional nanosecond field to 0x2.
  • DriftAdjustRate = 0x5.