On Tue, 20 Nov 2007 05:04:23 -0800 (PST), xenix < XXXX@XXXXX.COM >
Write a piece of Tcl. Use "echo" to send stuff to the transcript
window rather than Tcl's regular "puts", because "puts" sends
things to the OS console, and you want it to go to ModelSim's
transcript window.
set text_file_handle [open "RESULT.TXT" w]
...
set T [scaleTime $now 1ns]
set a_in [examine /top/dut/a_in]
set message [format {<At T=%s a_in="%s">} $T $a_in]
echo $message
puts $text_file_handle $message
...
close $text_file_handle
Save your Tcl script in a file (conventionally, use either
the .do or .tcl extension) and then use ModelSim's [do]
command, or the traditional Tcl [source] commmand, to
execute it.
--
Jonathan Bromley, Consultant
DOULOS - Developing Design Know-how
VHDL * Verilog * SystemC * e * Perl * Tcl/Tk * Project Services
Doulos Ltd., 22 Market Place, Ringwood, BH24 1AW, UK
XXXX@XXXXX.COM
http://www.**--****.com/
The contents of this message may contain personal views which
are not the views of Doulos Ltd., unless specifically stated.