Christoph Weiser
05/16/2024, 8:46 AMJunbeom Park
05/16/2024, 8:58 AMChristoph Weiser
05/16/2024, 9:10 AMStefan Schippers
05/16/2024, 9:45 AMStefan Schippers
05/16/2024, 9:48 AMcomp3_empty.sch
will be searched for in the search paths in the order they are given in XSCHEM_LIBRARY_PATH. The first match will be used.Stefan Schippers
05/16/2024, 9:52 AM.
listed in XSCHEM_LIBRARY_PATH. Use [pwd]
.
example:
append XSCHEM_LIBRARY_PATH :[pwd]
instead of:
append XSCHEM_LIBRARY_PATH :.
this because .
in XSCHEM_LIBRARY_PATH
does NOT mean the current working directory (ie where xschem is started) but the directory of the current schematic (the one containing the symbols we are discussing about).Christoph Weiser
05/16/2024, 10:53 AMset DESIGN_PATH [exec pwd]
set XSCHEM_LIBRARY_PATH :${DESIGN_PATH}/xschem/symbols
append XSCHEM_LIBRARY_PATH :${DESIGN_PATH}
I cannot exactly recall why I did what i did, but there was some reason for why I did it in this order.Stefan Schippers
05/16/2024, 5:43 PMpwd
is ok. Just don't use '`.' which has in xschem a different meaning. (
.` is an alias for the directory where the current schematic is stored, so it is not a fixed path. This could be useful in some use cases but definitely not in other cases).
PS: Do not use exec pwd
, pwd
is also a tcl builtin, much faster.
tclsh8.6 [~] time {pwd}
22 microseconds per iteration
tclsh8.6 [~] time {exec pwd}
2666 microseconds per iteration
Christoph Weiser
05/16/2024, 5:46 PMChristoph Weiser
05/16/2024, 5:58 PMset DESIGN_PATH [pwd]
set XSCHEM_LIBRARY_PATH :${DESIGN_PATH}
append XSCHEM_LIBRARY_PATH :${DESIGN_PATH}/xschem/symbols
The symbol instance looks like this.
name=xcd
schematic=alternative.sch
When i try to netlist the testbench it will point down the tesbench direction path and not down into the path where the symbol is.Stefan Schippers
05/16/2024, 6:17 PMStefan Schippers
05/16/2024, 6:19 PMChristoph Weiser
05/16/2024, 6:25 PMChristoph Weiser
05/16/2024, 6:28 PMStefan Schippers
05/16/2024, 6:35 PMSymbol
textbox (see red ellipse) ?Christoph Weiser
05/16/2024, 6:37 PMsch/experiment/comp.sym
Stefan Schippers
05/16/2024, 6:38 PMschematic="sch/experiment/comp_alt.sch"
Stefan Schippers
05/16/2024, 6:40 PM$DESIGN_PATH/sch/experiment
to the XSCHEM_LIBRARY_PATH
.
append XSCHEM_LIBRARY_PATH :$DESIGN_PATH/sch/experiment
Christoph Weiser
05/16/2024, 6:43 PMChristoph Weiser
05/16/2024, 6:46 PMXSCHEM_LIBRARY_PATH
seems less preferable to me because i will modify and clutter up my xschemrc.Stefan Schippers
05/16/2024, 6:47 PM/a:/b:/a/c
and schematic reference is d/comp.sch
then the following locations are tried in this order:
/a/d/comp.sch
/b/d/comp.sch
/a/c/d/comp.sch
search stops at first file found.Christoph Weiser
05/16/2024, 6:48 PMStefan Schippers
05/16/2024, 6:52 PMschematic=/home/user/design/sch/experiment/comp.sch
but it is obviously not recommended.Christoph Weiser
05/16/2024, 6:56 PM