Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using wlf as input

Status
Not open for further replies.

sheenjrg

Programmer
Oct 14, 2003
14
US
Hey guys I need to use the output of a testbench as an input to another. I mean if I generate a waveform from one testbench, can it be used as an input to another module at a later time? Or in other words can I save a waveform and use it later as an input signal for another program?
 
Sure, then dumb way to do it would be to write some code to dump the results into some file format that you control... then write some more code to read it back at a later time.

That would work regardless of your simulator (assuming it supports standard textio libraries).

As for using WLF (or equivalent) files.. I am unsure. I don't see (in theory) why it couldn't be done. It would depend on your simulator. I don't have much experience with anything but Modelsim so I am unsure if WLF is a Modelsim only thing, or a standard, but in any event I guess most simulators would have some form of waveform log.

Looking in the Modelsim user guide it says:
"Any number of WLF file can be reloaded for viewing or comparing to the active simulation".
There doesn't seem to be any mention of what you are trying to do, and this sentence seems to imply all the options your have with WLFs.

However I agree that it would be nice to be able to build a little testbench that says "strip signal ABC output of filename.wlf and output it as signal DEF".

Of course you could write the code yourself if you knew the format and could generate some text file from the wlf file.... not especially nice though.. a built in modelsim feature would be nicer.
 
Hmm.. seems like WLF is a modelsim format:
A few examples:
SHM (Cadence)
VPD (VCS)
WLF (Modelsim)

You could try creating a VCD from your WLF and trying to write some code to strip out a signal. I haven't really looked inside a VCD to see if it is just impossible to do with VHDL. But at least its ASCII and you might be able to write a perl script to extract a signal to put into a testbench.
 
Thanks for the help dude. You are right I am using Modelsim. I too thought of the same thing from the manual where is says we can use the waveform to view and read but was not sure if we can use it as input. Well if u come up with something let me know.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top