class RegCntrlAgent(SyncAgentBase): """ Simulation/verification agent for RegCntrl interface """ def __init__(self, intf): AgentBase.__init__(self, intf) super().__init__(intf) self._din = SignalAgent(intf.din) self._dout = VldSyncedAgent(intf.dout, allowNoReset=True) def din_getter(self): return self._din.data def din_setter(self, newVal): self._din.data = newVal din = property(din_getter, din_setter) def dout_getter(self): return self._dout.data def dout_setter(self, newVal): self._dout.data = newVal dout = property(dout_getter, dout_setter) def getDrivers(self): return self._din.getMonitors() + self._dout.getDrivers() def getMonitors(self): return self._din.getDrivers() + self._dout.getMonitors()
def __init__(self, sim, intf): super().__init__(sim, intf) self._din = SignalAgent(sim, intf.din) self._dout = VldSyncedAgent(sim, intf.dout, allowNoReset=True)
def _initSimAgent(self): self._ag = VldSyncedAgent(self)
def _initSimAgent(self, sim: HdlSimulator): self._ag = VldSyncedAgent(sim, self)
def getMonitors(self): self.is_monitor = True return VldSyncedAgent.getMonitors(self)
def __init__(self, sim: HdlSimulator, intf, allowNoReset=False): VldSyncedAgent.__init__(self, sim, intf, allowNoReset=allowNoReset) self.is_monitor = False self.actual_frame = [] self.frames = deque()
def __init__(self, sim: HdlSimulator, intf, allowNoReset=False): VldSyncedAgent.__init__(self, sim, intf, allowNoReset=allowNoReset) self.has_mask = hasattr(intf, "mask")