From 73dbffe8f209313297549825f7b45d663230e798 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Thu, 20 Jun 2019 09:02:08 +0200 Subject: [PATCH] cores/frequency_meter: allow passing clk to be measured as a parameter --- litex/soc/cores/frequency_meter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/litex/soc/cores/frequency_meter.py b/litex/soc/cores/frequency_meter.py index 3e6159ee..522de1fd 100644 --- a/litex/soc/cores/frequency_meter.py +++ b/litex/soc/cores/frequency_meter.py @@ -32,8 +32,8 @@ class Sampler(Module): class FrequencyMeter(Module, AutoCSR): - def __init__(self, period, width=6): - self.clk = Signal() + def __init__(self, period, width=6, clk=None): + self.clk = Signal() if clk is None else clk self.value = CSRStatus(32) # # # -- 2.30.2