From: Sebastien Bourdeauducq Date: Wed, 5 Dec 2012 15:40:12 +0000 (+0100) Subject: actorlib/sim: drive busy high until generator is finished X-Git-Tag: 24jan2021_ls180~2099^2~726 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=34ce934809cf4bd451d23352efd564692b86e426;p=litex.git actorlib/sim: drive busy high until generator is finished --- diff --git a/migen/actorlib/sim.py b/migen/actorlib/sim.py index 00848e3f..e6885225 100644 --- a/migen/actorlib/sim.py +++ b/migen/actorlib/sim.py @@ -73,8 +73,11 @@ class SimActor(Actor): super().__init__(*endpoint_descriptions, **misc) self.token_exchanger = TokenExchanger(generator, self) + def update_busy(self, s): + s.wr(self.busy, not self.token_exchanger.done) + def get_fragment(self): - return self.token_exchanger.get_fragment() + return self.token_exchanger.get_fragment() + Fragment(sim=[self.update_busy]) class Dumper(SimActor): def __init__(self, layout, prefix=""):