Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How to show the current simulation time

2 views
Skip to first unread message

boku...@gmail.com

unread,
Aug 31, 2006, 10:19:10 AM8/31/06
to
Dear all,
How to use "now" to display the current simulation time? Thank
you~~~

Best Regards,

Mike Treseler

unread,
Aug 31, 2006, 1:06:39 PM8/31/06
to
boku...@gmail.com wrote:
> Dear all,
> How to use "now" to display the current simulation time? Thank

Easiest way is to use the report command.
If I say:

report " Hello World!" ;

in my testbench,
I will get this in the transcript:

# ** Note: Hello World!
# Time: 105 ns Iteration: 1 Instance: /test_mydesign

-- Mike Treseler

Andy

unread,
Aug 31, 2006, 4:54:35 PM8/31/06
to
How about something like

Report time'image(now);

Andy

Paul Uiterlinden

unread,
Sep 1, 2006, 3:47:43 PM9/1/06
to
boku...@gmail.com wrote:

> Dear all,
> How to use "now" to display the current simulation time? Thank
> you~~~
>

USE std.textio.ALL;
...
VARIABLE l: line;
...
write(l, string'("The current simulation time is: "));
write(l, now);
writeline(output, l);

This will write to stdout: the simulator window.

--
Paul.

0 new messages