Is there any way to tell an alter statement to look for a parameter in the same scope as where the alter statement appears? For example, suppose I have a really basic model file that includes some alter statements like this:
// myfile.scs
section params
parameters VDD=3.3
endsection params
section nom
include "myfile.scs" section=params
ALT_VDD alter param=VDD value=3.3
ALT_temp alter param=temp value=27
endsection nom
section slow
include "myfile.scs" section=params
ALT_VDD alter param=VDD value=3.0
ALT_temp alter param=temp value=125
endsection slow
When I include this in a non-MTS simulation the alter statements work. But now if I use this as an MTS model file in something like:
// MTS block
subckt tech1_cell IN OUT
include "myfile.scs" section=nom
// rest of technology #1 netlist
ends tech1_cell
// MTS block
subckt tech2_cell IN OUT
include "myothermodels.scs" section=nom
// rest of technology #2 netlist
ends tech2_cell
ITECH1A (T1INA T1OUTA) tech1_cell
ITECH1B (T1INB T1OUTB) tech1_cell
ITECH2 (T2IN T2OUT) tech2_cell
// rest of technology independent netlist
// spectre analysis statements
I have a problem which is the alter statements in the "myfile.scs" model file run in the top level scope and look for a top level parameter called "VDD" instead of the parameter that is local to the "tech1_cell" scope. In addition, the temperature change is global and not to the two instances of tech1_cell. I can't use "sub=ITECH1A" on those alter statements because the model file is not supposed to need to know details about the circuit that uses it and on top of that in this case I instantiated 2 instances of "tech1_cell".
Am I missing some useful keyword that will make it all just work or is this one of the things that MTS sims just don't really support at this time?