send = True
else:
send = randint(0, send_range) != 0
+ send = True
o_p_ready = yield self.dut.p.o_ready
if not o_p_ready:
yield
@property
def p_o_ready(self):
return Const(1)
+ return self.count == 0
@property
def n_o_valid(self):
"""
return i + 1
+ def elaborate(self, platform):
+ m = Module()
+ m.d.sync += self.count.eq(~self.count)
+ return m
+
class ExampleBufDelayedPipe(BufferedPipeline):
""" an example of how to use the buffered pipeline.
stage = ExampleStageDelayCls()
BufferedPipeline.__init__(self, stage, stage_ctl=True)
+ def elaborate(self, platform):
+ m = BufferedPipeline.elaborate(self, platform)
+ m.submodules.stage = self.stage
+ return m
+
class ExampleBufPipe3(ControlBase):
""" Example of how to do delayed pipeline, where the stage signals