actorlib/sim: drive busy high until generator is finished
This commit is contained in:
parent
4bcb39699b
commit
34ce934809
|
@ -73,8 +73,11 @@ class SimActor(Actor):
|
||||||
super().__init__(*endpoint_descriptions, **misc)
|
super().__init__(*endpoint_descriptions, **misc)
|
||||||
self.token_exchanger = TokenExchanger(generator, self)
|
self.token_exchanger = TokenExchanger(generator, self)
|
||||||
|
|
||||||
|
def update_busy(self, s):
|
||||||
|
s.wr(self.busy, not self.token_exchanger.done)
|
||||||
|
|
||||||
def get_fragment(self):
|
def get_fragment(self):
|
||||||
return self.token_exchanger.get_fragment()
|
return self.token_exchanger.get_fragment() + Fragment(sim=[self.update_busy])
|
||||||
|
|
||||||
class Dumper(SimActor):
|
class Dumper(SimActor):
|
||||||
def __init__(self, layout, prefix=""):
|
def __init__(self, layout, prefix=""):
|
||||||
|
|
Loading…
Reference in New Issue