I've been looking over manuals and posts and can't seem to find an answer to this:
I have a several dc files to improve convergence of DC simulation. Each DC-file refer to a different value of a variable. i.e: DAC__GainControl_0.dc, DAC__GainControl_5.dc, DAC__GainControl_10.dc ecc...
In my variable list I define 2 variables:
GainControl_VAR (which I change according to my needs from 0 to 100 with step of 5)
filename_DC=sprintf( nil "/myworkspace/DAC__GainControl_%d.dc" GainControl_VAR) which I use in the read-operating-point section of a DC test
I first run a DC-test in adexl calledl TEST_DC reading the operating point from one of the pre-saved list of DC files: here is a numerical example
GainControl_VAR=50 (globally defined) ----> filename_DC=/myworkspace/DAC__GainControl_50.dc
TEST_DC generates an output expression called GainControl_VAR_DC which represents the value that the variable GainControl_VAR should have in a second test called TEST_HB. Assume in this example that the value is:
GainControl_VAR_DC =20
Therefore in TEST_HB I define locally: GainControl_VAR=calcVal("GainControl_VAR_DC" "TEST_DC"), (in my example in TEST_HB -------> GainControl_VAR=20)
Also I want TEST_HB to read the dc-file associated to the new value of GainControl_VAR (In my example I want TEST_HB to read teh dc file /myworkspace/DAC__GainControl_20.dc)
The Question is how to do that?
If I define globally: filename_DC=sprintf( nil "/myworkspace/DAC__GainControl_%d.dc" GainControl_VAR) -----> It picks up the global value of the variable (in my example it is 50) and therefore the filepath is /myworkspace/DAC__GainControl_50.dc
If I define locally: filename_DC=sprintf( nil "/myworkspace/DAC__GainControl_%d.dc" calcVal("GainControl_VAR_DC" "TEST_DC")) -----> I get simulation error from TEST_HB and looking in the netlist it seems it cannot recognize the expression