clock/lattice_ecp5/ECP5PLL: emit frequency annotations to help Diamond

Unlike nextpnr, Diamond appears not to infer the frequency of the
outputs.  Emit the same attributes that Diamond's PLL tool does.
This commit is contained in:
George Hilliard 2021-09-15 00:00:54 -05:00
parent 6733a3e3e6
commit 91ec6e0da8
1 changed files with 2 additions and 0 deletions

View File

@ -162,4 +162,6 @@ class ECP5PLL(Module):
self.params[f"p_CLKO{n_to_l[n]}_FPHASE"] = 0
self.params[f"p_CLKO{n_to_l[n]}_CPHASE"] = cphase
self.params[f"o_CLKO{n_to_l[n]}"] = clk
if f > 0: # i.e. not a feedback-only clock
self.params["attr"].append((f"FREQUENCY_PIN_CLKO{n_to_l[n]}", str(f/1e6)))
self.specials += Instance("EHXPLLL", **self.params)