Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > VHDL > simulation script

Reply
Thread Tools

simulation script

 
 
JohnSmith
Guest
Posts: n/a
 
      06-08-2011
Hi,

How can I use an environment variable in a ".do" script running it in
the modelsim window?

I tried the windows environment variable in % characters, but doesnt
work. Absolute paths work but I want use this scripts on different
computers.

vsim -sdftyp {/UUT=%MYDIR%/dir/.../timesim.sdf} ...

Thanks

 
Reply With Quote
 
 
 
 
MJB
Guest
Posts: n/a
 
      06-08-2011
On Jun 8, 9:32*am, JohnSmith <(E-Mail Removed)> wrote:
> Hi,
>
> How can I use an environment variable in a ".do" script running it in
> the modelsim window?
>
> I tried the windows environment variable in % characters, but doesnt
> work. Absolute paths work but I want use this scripts on different
> computers.
>
> vsim -sdftyp {/UUT=%MYDIR%/dir/.../timesim.sdf} ...
>
> Thanks


Try using the Tcl env() function. Modelsim's shell is essentially a
Tcl command line evironment and the .do files are .tcl scripts.

to get your directory, try /UUT=env(MYDIR)/ .....

I don't have a Modelsim installation handy so this is just off the top
of my head. Hope you find the solution!
 
Reply With Quote
 
 
 
 
JohnSmith
Guest
Posts: n/a
 
      06-08-2011
On Jun 8, 6:45*pm, MJB <(E-Mail Removed)> wrote:
> On Jun 8, 9:32*am, JohnSmith <(E-Mail Removed)> wrote:
>
> > Hi,

>
> > How can I use an environment variable in a ".do" script running it in
> > the modelsim window?

>
> > I tried the windows environment variable in % characters, but doesnt
> > work. Absolute paths work but I want use this scripts on different
> > computers.

>
> > vsim -sdftyp {/UUT=%MYDIR%/dir/.../timesim.sdf} ...

>
> > Thanks

>
> Try using the Tcl env() function. *Modelsim's shell is essentially a
> Tcl command line evironment and the .do files are .tcl scripts.
>
> to get your directory, try /UUT=env(MYDIR)/ .....
>
> I don't have a Modelsim installation handy so this is just off the top
> of my head. *Hope you find the solution!


Doesnt work..

 
Reply With Quote
 
HT-Lab
Guest
Posts: n/a
 
      06-09-2011
On 08/06/2011 18:00, JohnSmith wrote:
> On Jun 8, 6:45 pm, MJB<(E-Mail Removed)> wrote:
>> On Jun 8, 9:32 am, JohnSmith<(E-Mail Removed)> wrote:
>>
>>> Hi,

>>
>>> How can I use an environment variable in a ".do" script running it in
>>> the modelsim window?

>>
>>> I tried the windows environment variable in % characters, but doesnt
>>> work. Absolute paths work but I want use this scripts on different
>>> computers.

>>
>>> vsim -sdftyp {/UUT=%MYDIR%/dir/.../timesim.sdf} ...

>>
>>> Thanks

>>
>> Try using the Tcl env() function. Modelsim's shell is essentially a
>> Tcl command line evironment and the .do files are .tcl scripts.
>>
>> to get your directory, try /UUT=env(MYDIR)/ .....
>>
>> I don't have a Modelsim installation handy so this is just off the top
>> of my head. Hope you find the solution!

>
> Doesnt work..
>

MJB forgot the variable sign,

vsim -sdftyp /UUT=$env(MYDIR)...

Hans
www.ht-lab.com



 
Reply With Quote
 
MJB
Guest
Posts: n/a
 
      06-24-2011
On Jun 9, 12:45*am, HT-Lab <(E-Mail Removed)> wrote:
> On 08/06/2011 18:00, JohnSmith wrote:
>
>
>
>
>
>
>
> > On Jun 8, 6:45 pm, MJB<(E-Mail Removed)> *wrote:
> >> On Jun 8, 9:32 am, JohnSmith<(E-Mail Removed)> *wrote:

>
> >>> Hi,

>
> >>> How can I use an environment variable in a ".do" script running it in
> >>> the modelsim window?

>
> >>> I tried the windows environment variable in % characters, but doesnt
> >>> work. Absolute paths work but I want use this scripts on different
> >>> computers.

>
> >>> vsim -sdftyp {/UUT=%MYDIR%/dir/.../timesim.sdf} ...

>
> >>> Thanks

>
> >> Try using the Tcl env() function. *Modelsim's shell is essentially a
> >> Tcl command line evironment and the .do files are .tcl scripts.

>
> >> to get your directory, try /UUT=env(MYDIR)/ .....

>
> >> I don't have a Modelsim installation handy so this is just off the top
> >> of my head. *Hope you find the solution!

>
> > Doesnt work..

>
> MJB forgot the variable sign,
>
> vsim -sdftyp /UUT=$env(MYDIR)...
>
> Hanswww.ht-lab.com


Thanks for the correction!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to execute a script from another script and other script does notdo busy wait. Rajat Python 3 01-08-2010 02:05 PM
RE: How to execute a script from another script and other script doesnotdo busy wait. VYAS ASHISH M-NTB837 Python 2 01-07-2010 08:18 PM
Problem with post-route simulation / timing simulation jasperng VHDL 0 11-27-2008 06:23 AM
Control Modelsim simulation from Perl Script Chendu Perl Misc 0 10-25-2006 11:40 AM
VHDL Simulation for Linux Neil Zanella VHDL 2 08-04-2003 01:11 PM



Advertisments