litex/test/test_la.py

27 lines
537 B
Python
Raw Normal View History

from litescope.host.driver.la import LiteScopeLADriver
2015-01-22 18:31:57 -05:00
def main(wb):
wb.open()
###
la = LiteScopeLADriver(wb.regs, "la", debug=True)
2015-01-22 18:31:57 -05:00
#cond = {"cnt0" : 128} # trigger on cnt0 = 128
cond = {} # trigger on cnt0 = 128
la.configure_term(port=0, cond=cond)
la.configure_sum("term")
la.configure_subsampler(1)
#la.configure_qualifier(1)
la.configure_rle(1)
la.run(offset=128, length=256)
2015-01-22 18:31:57 -05:00
while not la.done():
pass
la.upload()
2015-01-22 18:31:57 -05:00
la.save("dump.vcd")
la.save("dump.csv")
la.save("dump.py")
la.save("dump.sr")
###
wb.close()