Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to pass arguments to PrimeTime TCL script? (using pt_shell -file myScript.tcl )

Status
Not open for further replies.

majd229

Member level 2
Joined
Jul 21, 2017
Messages
44
Helped
0
Reputation
0
Reaction score
0
Trophy points
6
Activity points
392
I want to allow user to pass some variables (lib file path, some constraint values, etc). How can i do that with a PT -file command?

eg. In tcl file i want to have:
set timing_lib_path [lindex $argv 0]
set_app_var link_path $timing_lib_path
etc...


Then I want user to run:
pt_shell -file myScript.tcl /path/to/timing.lib


However, ptshell doesnt understand that anything after the "-file myScript.tcl " is an input argument to the tcl code itself and i get an error saying there are extra positional args. How can i do that? How can i allow any sort of input arg to a tcl code to run in batch mode?


Thank you
 

I want to allow user to pass some variables (lib file path, some constraint values, etc). How can i do that with a PT -file command?

eg. In tcl file i want to have:
set timing_lib_path [lindex $argv 0]
set_app_var link_path $timing_lib_path
etc...


Then I want user to run:
pt_shell -file myScript.tcl /path/to/timing.lib


However, ptshell doesnt understand that anything after the "-file myScript.tcl " is an input argument to the tcl code itself and i get an error saying there are extra positional args. How can i do that? How can i allow any sort of input arg to a tcl code to run in batch mode?


Thank you

it's probably easier to set environment variables in your linux system and use those in the script
 

I want to allow user to pass some variables (lib file path, some constraint values, etc). How can i do that with a PT -file command?

eg. In tcl file i want to have:
set timing_lib_path [lindex $argv 0]
set_app_var link_path $timing_lib_path
etc...


Then I want user to run:
pt_shell -file myScript.tcl /path/to/timing.lib


However, ptshell doesnt understand that anything after the "-file myScript.tcl " is an input argument to the tcl code itself and i get an error saying there are extra positional args. How can i do that? How can i allow any sort of input arg to a tcl code to run in batch mode?


Thank you

A workaround may be creating top script (main.csh) where you can pass arguments when you call it ($1, $2). Consequently, this script will modify your script (myScript.tcl), and at the end you just call prime time automatically by means of the main.csh
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top