self.pll_test_o = Signal(reset_less=True)
self.pll_vco_o = Signal(reset_less=True)
self.clk_sel_i = Signal(2, reset_less=True)
+ self.ref_clk = Signal(reset_less=True)
+ self.pllclk_clk = ClockSignal("pllclk")
def elaborate(self, platform):
m = Module()
# PLL clock established. has the side-effect of running clklsel
# at the PLL's speed (see DomainRenamer("pllclk") above)
- pllclk = ClockSignal("pllclk")
+ pllclk = self.pllclk_clk
comb += pllclk.eq(pll.clk_pll_o)
# wire up external 24mhz to PLL
# XXX BYPASS PLL XXX
# XXX BYPASS PLL XXX
# XXX BYPASS PLL XXX
- if False and self.pll_en:
- comb += intclk.eq(pllclk)
+ if self.pll_en:
+ comb += intclk.eq(self.ref_clk)
else:
comb += intclk.eq(ClockSignal())
if self.ti.dbg_domain != 'sync':
ports.append(self.clk_sel_i)
ports.append(self.pll_test_o)
ports.append(self.pll_vco_o)
+ ports.append(self.pllclk_clk)
+ ports.append(self.ref_clk)
return ports