After a value has been established in the system_timer
, it begins to increment by a fixed amount on a cycle-to-cycle
basis. This fixed amount is labeled as timer_increment
on
the block diagram.
The amount of the increment can be adjusted in one of three methods. The
desired method is selected using the signal ctl_D_ptp_st_adjust_type_N
input. The update value is provided by D_ptp_st_adjust_N
and the operation is triggered by toggling the
value of D_ptp_st_adjust_vld_N
.
Updates can be performed at any time, although changes should only be performed once every 10 clocks (system clocks) to avoid issues with retiming.
- Method 1: Phase Adjustment (type = 2’b00)
- The
system_timer
can be shifted in time by a specific amount (that is, a phase shift) using the system timer phase adjustment method. The provided adjustment is signed and is in units of 2-8 ns which are directly added tosystem_timer
in addition to the usual timer increment. It is a one-time adjustment and you must repeat the operation again to add another amount. The maximum shift is (+/- 217 - 1) × 2-8 ns, or approximately +/- 0.5 µs. - Method 2: Coarse Frequency Set (type = 2’b01)
- In this mode, you can define a new increment value that is to be added
to
system_timer
on a clock-by-clock basis. The provided increment value is interpreted as an unsigned integer in units of 2-8 ns (maximum 10 bits). When a coarse adjustment is made, the bottom 32 bits of the increment value are zeroed out (the internal increment value has a granularity of 2-40 ns). To make more fine-grained adjustments (< 2-8 ns) toincrement_value
, the next method must be used.
- Method 3: Fine Frequency Adjust (type = 2’b10)
- This method allows you to make sub-nanosecond adjustments to the interval value. The provided increment value is interpreted as a signed integer in units of 2-40 ns. It is added to the existing timer increment. This is a signed value, so subtraction is possible if a negative adjustment is provided.