# Register to Register Path with Clock Jitter¶

The diagram above shows the timing path used previously for the simple register to register path analysis. This time we will assume the CLK source is a PLL or oscillator output and variations in cycle times occur. Clock edge times can vary from the ideal rising edge time, , by a value specified by the manufacturer commonly called Period Jitter.

## Setup Analysis¶

The timing diagram below shows the CLK1 with Jitter added to the rising edges. Without Jitter, the edges would occur at 100ns and 150ns, the ideal rising edge times. With Jitter, the rising edges occur at and .

The list below shows the delays and constraints that need to be considered for setup analysis of the path from register 1 to register 2.

- R1 Clock-to-Q Delay Maximum
- CL Propagation Delay Maximum
- R2 Setup Constraint Minimum
- Clock Skew
- Tc The Clock Period Minimum

(1)

is the minimum clock period and the maximum clock frequency can be calculate using

(2)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | ```
from ta_py_lib.td.logic import *
if "new.tim" != taApp.getFileName():
taApp.fileNew("TimingDiagram")
td = taApp.getTimingDiagram()
td.startScript()
jm = td.add_jitter_margin("tjitter", 1, 1, "Example Clock Jitter")
clk2q = td.add_part_delay("tclk2q", 6, 8, 10, "DFF Clock to Q Output Delay")
pd = td.add_part_delay("tpd", 2, 4, 6, "Combinatorial Logic Delay")
setup = td.add_part_constraint("tsetup", 4, 4, "DFF Setup Constraint")
hold = td.add_part_constraint("thold", 2, 2, "DFF Hold Constraint")
clk = td.add_digital_clock("CLK","H",20.0e6)
clk_e4 = clk.get_edge_list().get(4)
clk_e6 = clk.get_edge_list().get(6)
clk_e4.add_jitter_margin(jm)
clk_e6.add_jitter_margin(jm)
pwl = td.add_pulse_width_label(clk_e4, clk_e6, "Tc", "Center")
d1 = td.add_digital_signal("D1","L")
d1_e1 = d1.add_edge(95, "H")
d1_e2 = d1.add_edge(105, "L")
q1 = add_dff_re(td, d1, clk, 'Q1', setup, hold, clk2q)
d2 = add_comb_logic(td, q1, "D2", pd )
q2 = add_dff_re(td, d2, clk, 'Q2', setup, hold, clk2q)
td.stopScript()
``` |

## Hold Analysis¶

The timing diagram below shows the minimum and are used for hold time analysis.

The list below shows the delays and constraints that need to be considered for hold analysis of the path from register 1 to register 2.

- R1 Clock-to-Q Delay Minimum
- CL Propagation Delay Minimum
- R2 Hold Constraint Maximum
- Clock Skew

(3)