CRG: use new Module API
authorSebastien Bourdeauducq <sebastien@milkymist.org>
Fri, 15 Mar 2013 09:48:43 +0000 (10:48 +0100)
committerSebastien Bourdeauducq <sebastien@milkymist.org>
Fri, 15 Mar 2013 09:48:43 +0000 (10:48 +0100)
mibuild/crg.py

index 0d4dcfbb5e80ba56f291a805127172ae8dac8daf..6448ec49c6e7cdeae14889cae817f53db3ae3ad0 100644 (file)
@@ -1,6 +1,7 @@
 from migen.fhdl.structure import *
+from migen.fhdl.module import Module
 
-class CRG:
+class CRG(Module):
        def get_clock_domains(self):
                r = dict()
                for k, v in self.__dict__.items():
@@ -8,9 +9,6 @@ class CRG:
                                r[v.name] = v
                return r
 
-       def get_fragment(self):
-               return Fragment()
-
 class SimpleCRG(CRG):
        def __init__(self, platform, clk_name, rst_name):
                        self.cd = ClockDomain("sys")