mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
soc/cores/clock/intel_common: cleanup
This commit is contained in:
parent
3836e8a36c
commit
d89d6dfd0a
1 changed files with 5 additions and 5 deletions
|
@ -115,10 +115,10 @@ class IntelClocking(Module, AutoCSR):
|
|||
o_LOCKED = self.locked,
|
||||
)
|
||||
for n, (clk, f, p, m) in sorted(self.clkouts.items()):
|
||||
clk_phase_ps = int((1e12/config["clk{}_freq".format(n)])*config["clk{}_phase".format(n)]/360)
|
||||
self.params["p_CLK{}_DIVIDE_BY".format(n)] = config["clk{}_divide".format(n)]
|
||||
self.params["p_CLK{}_DUTY_CYCLE".format(n)] = 50
|
||||
self.params["p_CLK{}_MULTIPLY_BY".format(n)] = config["m"]
|
||||
self.params["p_CLK{}_PHASE_SHIFT".format(n)] = clk_phase_ps
|
||||
clk_phase_ps = int((1e12/config[f"clk{n}_freq"])*config[f"clk{n}_phase"]/360)
|
||||
self.params[f"p_CLK{n}_DIVIDE_BY"] = config[f"clk{n}_divide"]
|
||||
self.params[f"p_CLK{n}_DUTY_CYCLE"] = 50
|
||||
self.params[f"p_CLK{n}_MULTIPLY_BY"] = config["m"]
|
||||
self.params[f"p_CLK{n}_PHASE_SHIFT"] = clk_phase_ps
|
||||
self.comb += clk.eq(clks[n])
|
||||
self.specials += Instance("ALTPLL", **self.params)
|
||||
|
|
Loading…
Reference in a new issue