@cocotb.test()
def wishbone_basic(dut):
- """
- Test of an added Wishbone interface
+ """Test of an added Wishbone interface
+
+ for this test the soc JTAG TAP address width is 29 bits and data is 64
+ JTAG has access to the *full* memory range, including peripherals,
+ as defined by the litex setup.
"""
clk_period = 100 # 10MHz
tck_period = 300 # 3MHz
yield master.load_ir(cmd_MEMADDRESS)
dut._log.info("Loading address")
+ # WBaddresses in soc.debug.jtag.JTAG are 29 bits
data_in.binstr = "00000000000000000000000000001"
dut._log.info(" input: {}".format(data_in.binstr))
yield master.shift_data(data_in)
yield master.load_ir(cmd_MEMREADWRITE)
dut._log.info("Writing memory")
+ # data is 64-bit
data_in.binstr = "01010101" * 8
dut._log.info(" input: {}".format(data_in.binstr))
yield master.shift_data(data_in)