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