From 45f562d63caf5d4d9cfeec6870492999ed871691 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Wed, 25 Aug 2021 14:09:53 +0200 Subject: [PATCH] core/LiteScopeAnalyzer: Switch register parameter to boolean. --- litescope/core.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/litescope/core.py b/litescope/core.py index 7d4fa62..d35e44a 100644 --- a/litescope/core.py +++ b/litescope/core.py @@ -226,7 +226,7 @@ class _Storage(Module, AutoCSR): class LiteScopeAnalyzer(Module, AutoCSR): - def __init__(self, groups, depth, clock_domain="sys", trigger_depth=16, register=0, csr_csv="analyzer.csv"): + def __init__(self, groups, depth, clock_domain="sys", trigger_depth=16, register=False, csr_csv="analyzer.csv"): self.groups = groups = self.format_groups(groups) self.depth = depth @@ -245,7 +245,7 @@ class LiteScopeAnalyzer(Module, AutoCSR): sd = getattr(self.sync, clock_domain) for i, signals in groups.items(): s = Cat(signals) - for _ in range(register): + if register: s_d = Signal(len(s)) sd += s_d.eq(s) s = s_d