callback_base
¶
Base class for all callbacks.
Classes:
-
CallbackBase–Base class for all callbacks.
CallbackBase
¶
CallbackBase(dut)
Base class for all callbacks.
Parameters:
-
dut(Any) –cocotb dut reference.
Methods:
-
read–Finds the actual signal in RTL and returns its value.
-
write–Finds the actual signal in RTL and sets its value.
Source code in src/peakrdl_cocotb_ralgen/callbacks/callback_base.py
9 10 11 12 13 14 15 | |
read
¶
read(sigHash)
Finds the actual signal in RTL and returns its value.
Parameters:
-
sigHash(dict) –A dictionary of signal parameters " {"reg": register, "sig": signal_name, "low": signal's low index in the register, "high": signal's high index in the register, }
Source code in src/peakrdl_cocotb_ralgen/callbacks/callback_base.py
32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |
write
¶
write(sigHash, wr)
Finds the actual signal in RTL and sets its value.
Parameters:
-
sigHash(dict) –A dictionary of signal parameters " {"reg": register, "sig": signal_name, "low": signal's low index in the register, "high": signal's high index in the register, }
-
wr(int) –Integer value to write to the signal
Source code in src/peakrdl_cocotb_ralgen/callbacks/callback_base.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | |